Gutenberg icon indicating copy to clipboard operation
Gutenberg copied to clipboard

Remove embedded normalize

Open nwmcsween opened this issue 6 years ago • 5 comments

Instead of embedding normalize gutenberg should probably say it's required in the documentation then users could use a newer version of normalize

nwmcsween avatar Jul 16 '18 04:07 nwmcsween

Yes it could do it as a peer dependency, feel free to submit a patch.

BafS avatar Jul 19 '18 14:07 BafS

It appears the link in the gutenberg.scss is wrong. Instead of:

@import '../node_modules/normalize.css/normalize';

it should be:

@import '../../normalize.css/normalize';

ghost avatar Feb 19 '20 17:02 ghost

@fanchyfanch the path is correct, you can try to compile it with npx gulp. Do you include this file from another project ?

What we could do is use the tilda ~ (@import '~normalize.css/normalize') like webpack but it's not natively handled with gulp-sass.

BafS avatar Feb 19 '20 23:02 BafS

Actually, I'm loading gutenberg as a dependency in my project from SASS:

@import '~gutenberg-css/scss/gutenberg';

And when I compile my project with Webpack Encore, it throws an error "unable to find normalize.css".

I had to make an intermediary file to work as the "gutenberg.scss" entrypoint and to load every sub-files, including normalize.css like:

@import '~normalize.css/normalize';

ghost avatar Feb 20 '20 15:02 ghost

@fanchyfanch A new version was published (v0.6.0)

BafS avatar Mar 02 '20 23:03 BafS