Magento 2 Problem with CSS Loading – Troubleshooting Guide

cssmagento2theme-fallback

Whenever I edit app/design/frontend/Dzinehub/Theme/web/css/styles-l.css , it doesn't get reflected in the front end when I load the site .After every change , I have to clear the cache and run static content-deploy for the changes to appear.Is there any other way ?

Best Answer

You could run: setup:static-content:deploy OR delete the file(s) manually pub/static/frontend/...

While developing the first approach could be extremely slow so personally I prefer to remove the created files.

You can find a detailed explanation about code clean here

BTW: It is preferable edit .less instead .css files to maintain scalable and 'neat' your theme code.

Related Topic