Making css additions to the theme
Permalink Browser Info Environment
Hi there
We are trying to make some additional css styles for the theme and are writing them into the main.less file. Is there a way to always recompile this when developing on the site, so we can see our changes immidiately?
Look forward to your reply,
We are trying to make some additional css styles for the theme and are writing them into the main.less file. Is there a way to always recompile this when developing on the site, so we can see our changes immidiately?
Look forward to your reply,
Type: | Discussion |
---|---|
Status: | In Progress |
Hi there
Thank you for the reply.
We have all cache disabled already.
We have also thought of making it in a separate file, and will do this in the end if nothing else works. We would like it best though to have all classes in one file.
Thank you for the reply.
We have all cache disabled already.
We have also thought of making it in a separate file, and will do this in the end if nothing else works. We would like it best though to have all classes in one file.
In that case, why not develop the site by using an additional CSS file as metioned and then once happy and production ready copy all these styles back in to the main.less file and clear the cache.
I was running into this while developing locally. I ended up setting up a build tool (gulp, but grunt would work as well) and having it watch the .less files I was working on. This combined with liveReload and I had an automated refresh running on every saved .less file change. Let me know if you would like more details on how to setup.
If you are writing custom CSS that is not LESS based then you may be better just creating a new CSS file and call in the theme header. That would work.