Follow

postcss-import と postcss-normalize ではまった。

@import-normalize を先に書こうとすると、 postcss-import が @import must precede all other statements って何もしない。

プラグインは postcss-import, postcss-normalize の順で読み込み、CSS 側では @import "foo.css"; ... を先に書いて、 @import-normalize; をあとに書く。んで、 postcss-normalize のオプションにforceImport: true をいれる。

なんか以前似たようなことをしたようなしないような。。。

· · Web · 1 · 0 · 0

あれ、ダメじゃん postcss-normalize が後ろにきてるじゃん。

"Allows you to force an insertion of normalize.css rules at the beginning of the CSS file if no insertion point is specified." って、@import-normalize を入れなくても、スタイル定義を挿入するってことか。

css から @import-normalize とったら先頭にノーマライズはいったわ。

Sign in to participate in the conversation
Mastodon

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!