Updating CSS classes in production doesnt show changes
Ive noticed that anywhere that I adjust the css classes dynamically (select2 boxes and one of my stimulus controllers adds a border when a div is clicked) the classes are added but the display isnt updated on the webpage. Not sure what would cause this, Ive inspected the page and confirmed that the javascript is running, there are no errors and the css classes are added to the div, but just not displaying.
Heres a picture of the select2 boxes. You can see the UL html was added, and the select fields have the hidden property, but are still showing
Hey Alex,
Not sure it's related to this specific thing, but Jumpstart Pro uses PurgeCSS in production and staging to strip out any unused CSS to make the files as fast as possible. If you didn't have the class referenced in the locations it looks, it can strip out the class on accident when compiling.
You can tweak the whitelist for that in postcss.config.js in the repo and add your own classes to the whitelists so they don't get ignored. It also supports regex so you can use that to whitelist a set of classes too.