title: Angular Cloudinary width not working when using variables
body: <p>I have an issue with using <a href="https://cloudinary.com/documentation/angular_image_manipulation" rel="nofollow noreferrer">Cloudinary with Angular</a>.
  If I add a simple image like this:</p>
  <pre><code>&lt;cl-image class=&quot;img-fluid&quot; [public-id]=&quot;brand.image.publicId&quot; dpr=&quot;auto&quot; crop=&quot;scale&quot;&gt;
      &lt;cl-placeholder type=&quot;pixelate&quot;&gt;
      &lt;/cl-placeholder&gt;
      &lt;cl-transformation quality=&quot;auto&quot; fetch-format=&quot;auto&quot; width=&quot;500&quot;&gt;
      &lt;/cl-transformation&gt;
  &lt;/cl-image&gt;
  </code></pre>
  <p>This works fine.
  If I try then to add a width:</p>
  <pre><code>&lt;cl-image class=&quot;img-fluid&quot; [public-id]=&quot;brand.image.publicId&quot; dpr=&quot;auto&quot; crop=&quot;scale&quot;&gt;
      &lt;cl-placeholder type=&quot;pixelate&quot;&gt;
      &lt;/cl-placeholder&gt;
      &lt;cl-transformation width=&quot;150&quot; crop=&quot;thumb&quot;&gt;
      &lt;/cl-transformation&gt;
      &lt;cl-transformation quality=&quot;auto&quot; fetch-format=&quot;auto&quot; width=&quot;500&quot;&gt;
      &lt;/cl-transformation&gt;
  &lt;/cl-image&gt;
  </code></pre>
  <p>This also works. But I want my width to be a variable, not a static width. So I updated the code to this:</p>
  <pre><code>&lt;cl-image class=&quot;img-fluid&quot; [public-id]=&quot;brand.image.publicId&quot; dpr=&quot;auto&quot; crop=&quot;scale&quot; *ngIf=&quot;width&quot;&gt;
      &lt;cl-placeholder type=&quot;pixelate&quot;&gt;
      &lt;/cl-placeholder&gt;
      &lt;cl-transformation [width]=&quot;width&quot; crop=&quot;thumb&quot;&gt;
      &lt;/cl-transformation&gt;
      &lt;cl-transformation quality=&quot;auto&quot; fetch-format=&quot;auto&quot; width=&quot;500&quot;&gt;
      &lt;/cl-transformation&gt;
  &lt;/cl-image&gt;
  </code></pre>
  <p>And this doesn't work. It displays the image, but it has not resized it, which is no good.
  Notice this line:</p>
  <pre><code>&lt;cl-transformation [width]=&quot;width&quot; crop=&quot;thumb&quot;&gt;
  </code></pre>
  <p>It's like it is being ignored, also I made sure the component is not being created until a width was set by using <code>*ngIf=&quot;width&quot;</code>.</p>
  <p>Does anyone know why this isn't working?</p>