Closed maxnordlund closed 7 months ago
Parcel (and maybe other tools) is very picky where @import rules are allowed, otherwise you get this error message:
@import
🚨 @parcel/transformer-css: @import rules must precede all rules aside from @charset and @layer statements
I tracked down the culprit being this plugin, which prepends @font-face rules to the very top here:
@font-face
https://github.com/csstools/postcss-font-magician/blob/2587f19bc04bdc7f77e2b542041d63c4f3711596/index.js#L379-L380
Unfortunately I'm not familiar enough to fix it myself, but it would be nice if the @font-face rules where inserted just after the @import rules instead.
@import rules
This has been fixed and released in v4
v4
Parcel (and maybe other tools) is very picky where
@import
rules are allowed, otherwise you get this error message:I tracked down the culprit being this plugin, which prepends
@font-face
rules to the very top here:https://github.com/csstools/postcss-font-magician/blob/2587f19bc04bdc7f77e2b542041d63c4f3711596/index.js#L379-L380
Unfortunately I'm not familiar enough to fix it myself, but it would be nice if the
@font-face
rules where inserted just after the@import rules
instead.