stencil-storybook icon indicating copy to clipboard operation
stencil-storybook copied to clipboard

HMR css/scss variables

Open HarlesPilter opened this issue 4 years ago • 1 comments

Hey, First of all thanks for the great setup.

I'm having issues with HMR and changing the scss variables. For example changing the $color-primary, the change doesn't affect the component in storybook. Even reloading doesn't help and only after restarting the storybook/stencil combo the change is visible. I did also try this with CSS variables in _variables.scss file (did not work) or in init.scss (showed up in component after refresh). So my guess is it has something to do with the sass plugin and injectGlobalPaths.

I did try to follow how it all works but couldn't figure it out past where Stencil Dev Server Connector 2.0.3 gets injected into the storybook html. Any idea how to get HRM working for CSS/SCSS variables?

Cheers

HarlesPilter avatar Mar 23 '21 10:03 HarlesPilter

Hi Harles, this same issue we have aswell, stencil recognize the changes but didnt reloaded it. The only thing which works is to stop and start the storybook at the moment.

cheers

dutscher avatar Mar 25 '21 09:03 dutscher