lxsmnsyc / solid-styled

Reactive stylesheets for SolidJS
MIT License
173 stars 10 forks source link

fresh install - help to setup #27

Closed AverTry closed 9 months ago

AverTry commented 9 months ago

The Error: solid-styled.js Uncaught (in promise) Error: Unexpected use of css. Make sure that solid-styled's plugin is setup correctly.

Tested with fresh installs of,

vite 4.4.5 solidjs 1.7.8 vite 5.0.0 reverted to 4.4.5 solidjs 1.8.5 (Vite 5 not yet compatible with solidjs)


npm i solid-styled
npm i -D postcss

In app.jsx added before the App function return statement: import { css } from 'solid-styled';

css`
    .read-the-docs {
      color: red;
    }
  `;

Then error in browser console as mentioned at the top.

Also tried