JavaScript for WordPress Forums Gutenberg Development import './style.scss'; Reply To: import './style.scss';

#46926
Zac Gordon
Keymaster

Hey Jason!

Importing the css in this way is simply one of the styling patterns for React. Gutenberg Core uses it so for these reasons I’m using it here. In these examples, webpack is processing and spitting out the final css that we end up enqueuing.

You can also just have a single css file (or other architecture) and enqueue that. I think either way is probable fine and not a major benefit one way or the other if you don’t have a preference (or do :))

Hope that helps! Good question 🙂