You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
before upgrading to v5, everything went smooth, after the upgrade using css in className results in
You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).
Adding react({ jsxImportSource: '@emotion/react' }), to vite.config.ts fixes the issue, so it may be that jsxImportSource is not loaded from tsconfig.json, which should be the case according to the documentation? Or any other idea what may cause this?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
My tsconfig.json includes:
before upgrading to v5, everything went smooth, after the upgrade using
css
inclassName
results inAdding
react({ jsxImportSource: '@emotion/react' }),
to vite.config.ts fixes the issue, so it may be thatjsxImportSource
is not loaded from tsconfig.json, which should be the case according to the documentation? Or any other idea what may cause this?Edit: According to #9, this may be a regression.
Beta Was this translation helpful? Give feedback.
All reactions