Search code examples
magentomagento2magento-2.0

Magento 2 static cache


When I would change something in template, I need flush static cache(pub/static) because I didn't saw any changes in front end, but after that this folders has some empty folder and in front end I have some error ReferenceError: require is not defined and I need use this command c:\xampp\php\php.exe -f d:\projects\localsites\magento2.local\magento\bin\magento -- setup:static-content:deploy to generate static content. Maybe I do something wrong?


Solution

  • When you developing something for magento2 you should enable developer mode and static willn't has cache and will generation all requests.

    More about Magento 2 mods you can read on this page.