egoist / rollup-plugin-postcss

Seamless integration between Rollup and PostCSS.
MIT License
677 stars 217 forks source link

Can't get it to work with svelte #200

Open ralyodio opened 5 years ago

ralyodio commented 5 years ago
plugins: [
        postcss({
            extract: true,
            plugins: []
        }),
        svelte({
            // enable run-time checks when not in production
            dev: !production,
            // we'll extract any component CSS out into
            // a separate file — better for performance
            css: css => {
                css.write('public/bundle.css');
            }
        }),

Inside Login.svelte

<style>
    footer {
        display: flex;
        justify-content: space-between;
        align-items: center;

        & button {
            background-color: red;
        }
    }
</style>

Throws a complition error. doesn't like & for css-nesting.

ricochet1k commented 5 years ago

https://github.com/kaisermann/svelte-preprocess#with-rollup-plugin-svelte

ralyodio commented 5 years ago

This doesn't tell me how to use it with postcss.

On Fri, Oct 18, 2019 at 1:55 PM Matt Peterson notifications@github.com wrote:

https://github.com/kaisermann/svelte-preprocess#with-rollup-plugin-svelte

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/egoist/rollup-plugin-postcss/issues/200?email_source=notifications&email_token=AAAGV5MWKUTQSFBF3YMXRQDQPIPCXA5CNFSM4I5SQECKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBV6H7Q#issuecomment-543941630, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAGV5IH2P6UMI5YW5G2U53QPIPCXANCNFSM4I5SQECA .

-- Anthony Ettinger http://anthony.ettinger.name anthony@ettinger.name +1 (831) 406-1123

ralyodio commented 5 years ago

You did not set any plugins, parser, or stringifier. Right now, PostCSS does nothing. Pick plugins for your case on https://www .postcss.parts/ and use them in postcss.config.js.

ralyodio commented 5 years ago

the funny thing is works, but i get this warning message for some reason.