title: Echarts and bootstrap: responsive width
body: <p>With Echarts (from Baidu) i want put a pie chart inside a div element (i'm using bootstrap).</p>
  
  <p>So i have:</p>
  
  <pre><code>&lt;div class="row"&gt;
     &lt;div class="col-md-4"&gt;
        &lt;div id="chartGift" style="height:400px;"&gt;&lt;/div&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I've take the javascript code from the official documentation
      <a href="https://ecomfe.github.io/echarts/doc/example/pie1.html#-en" rel="noreferrer">https://ecomfe.github.io/echarts/doc/example/pie1.html#-en</a></p>
  
  <p>The problem is that the pie doesn't appear because, inspecting the html code, i see that the width is 0. Why echarts doesn't set the width from the parent element? I don't want set static width (i see that it works) because the chart isn't responsive.</p>