stitchesjs / stitches

[Not Actively Maintained] CSS-in-JS with near-zero runtime, SSR, multi-variant support, and a best-in-class developer experience.

Home Page:https://stitches.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not compatible with `moduleResolution: "Bundler"`

OnkelTem opened this issue · comments

Bug report

Describe the bug

A library using stitches cannot utilize "moduleResolution": "Bundler"

It leads to TS error:

TS2742: The inferred type of Button cannot be named without a reference to
../node_modules/@stitches/react/types/css-util
. This is likely not portable. A type annotation is necessary.

To Reproduce

Repo: https://github.com/OnkelTem/_stitches-inferred

  1. npm i
  2. npm run build

Expected behavior

No error

System information

  • OS: Linux
  • Version of Stitches: 1.2.8
  • Version of Node.js: 20.7.0