<p>Okay, so I figured this out and its a very stupid twig template noob mistake on my part. </p>

<p>The mistake is this:</p>

<p>I had a section called 'demo' with a field called 'demoField' and created a template folder called 'demo' with an index.html file inside. The mistake is that my template had this:</p>

<pre><code>{% for entry in craft.entries.section('demo').find() %}
    {{ entry.demoField }}
{% endfor %}
</code></pre>

<p>Looking at it now, this won't work, but simply <code>{{ entry.demoField }}</code> will work. </p>

<p>It threw me off because it was still showing the content in the template and saving it to the database, but the live preview would simply not work.</p>

<p>Quite a silly mistake, but just starting out I completely missed this. Hopefully this will help someone in the future.</p>

CC BY-SA 3.0
2014-11-16T22:36:00.257Z
2014-11-16T22:36:00.257Z
Ian
<p>May be because Craft CMS uses <code>gulp</code> for compiling the SASS and js and minimizes it ultimately. So you need too follow some steps,</p>

<p><strong>1).</strong>  Install <code>gulp</code> locally or globally(recomended),</p>

<p><code>sudo apt-get install gulp -g</code> or <code>sudo npm install gulp --save</code></p>

<p><strong>2).</strong> Need to run and make build everytime you change the CSS or JS files.</p>

<p><code>gulp build</code></p>

<p><strong>3).</strong> Or optionally <code>gulp</code> can track all the changes real time.</p>

<p><code>gulp watch</code></p>

<p>hope this will help you.</p>

CC BY-SA 4.0
2019-01-22T11:22:30.350Z
2019-01-22T11:22:30.350Z
Shahrukh Anwar
<p>Okay, first I know this question has been asked - specifically here: <a href="https://craftcms.stackexchange.com/questions/1643/live-preview-not-automatically-updating">Live preview not automatically updating</a></p>

<p>But that suggestion did not help. I have no console errors, no network errors. In fact, when I view the network tab in Chrome I can see it successfully POSTing the changes as I type in live preview mode. I have this set up on MAMP using craft.dev as the hostname.</p>

<p>I tried this in both Chrome and FireFox with no luck, as well as trying a fresh install of Craft with no success.</p>

<p>Any thoughts are greatly appreciated on what the issue might be.</p>

<p>Thanks.</p>

<javascript><editor>
Live Preview Not Updating - No errors found
# Live Preview Not Updating - No errors found

(Asked by: username_0 on 2014-11-16)

Okay, first I know this question has been asked - specifically here: [Live preview not automatically updating](https://craftcms.stackexchange.com/questions/1643/live-preview-not-automatically-updating)

But that suggestion did not help. I have no console errors, no network errors. In fact, when I view the network tab in Chrome I can see it successfully POSTing the changes as I type in live preview mode. I have this set up on MAMP using craft.dev as the hostname.

I tried this in both Chrome and FireFox with no luck, as well as trying a fresh install of Craft with no success.

Any thoughts are greatly appreciated on what the issue might be.

Thanks.

**Tags:** javascript, editor

---

## 2 answers

### Answer by username_0 on 2014-11-16. Score: 2

Okay, so I figured this out and its a very stupid twig template noob mistake on my part. 
The mistake is this:
I had a section called 'demo' with a field called 'demoField' and created a template folder called 'demo' with an index.html file inside. The mistake is that my template had this:
{% for entry in craft.entries.section('demo').find() %}
    {{ entry.demoField }}
{% endfor %}

Looking at it now, this won't work, but simply {{ entry.demoField }} will work. 
It threw me off because it was still showing the content in the template and saving it to the database, but the live preview would simply not work.
Quite a silly mistake, but just starting out I completely missed this. Hopefully this will help someone in the future.


---

### Answer by username_1 on 2019-01-22. Score: 1

May be because Craft CMS uses `gulp` for compiling the SASS and js and minimizes it ultimately. So you need too follow some steps,

**1).** Install `gulp` locally or globally(recomended),

`sudo apt-get install gulp -g` or `sudo npm install gulp --save`

**2).** Need to run and make build everytime you change the CSS or JS files.

`gulp build`

**3).** Or optionally `gulp` can track all the changes real time.

`gulp watch`

hope this will help you.


---

