Problem
packages/next/package.json (and the sibling framework packages that ship the same pattern) exports the stylesheet as a bare string:
"./styles": "./dist/tailwind-prefixed.css"
TypeScript 6.0 started type-checking side-effect imports, so a consumer on TS 6.x doing the documented
import '@upupjs/next/styles'
now fails to resolve declarations for the subpath (no types condition, no declaration file), forcing every TS 6 consumer to hand-write an ambient declare module '@upupjs/next/styles' shim.
Hit in production use: DevinoSolutions/GetItDone's TS 6.0.3 upgrade needed a local upup-styles.d.ts workaround for exactly this (verified against @upupjs/next / @upupjs/core 3.1.0, 2026-08-14).
Fix options
allowArbitraryExtensions-style declaration (TS-official mechanism): ship dist/tailwind-prefixed.d.css.ts next to the CSS and add a types condition:
"./styles": {
"types": "./dist/tailwind-prefixed.d.css.ts",
"default": "./dist/tailwind-prefixed.css"
}
- Or a plain empty ambient declaration (
declare module '@upupjs/next/styles';) shipped in dist and referenced by a types condition.
Either removes the consumer-side shim with no runtime change. Worth sweeping every framework package (react, vue, svelte, vanilla, angular, preact, next) that exposes a CSS subpath the same way.
Problem
packages/next/package.json(and the sibling framework packages that ship the same pattern) exports the stylesheet as a bare string:TypeScript 6.0 started type-checking side-effect imports, so a consumer on TS 6.x doing the documented
now fails to resolve declarations for the subpath (no
typescondition, no declaration file), forcing every TS 6 consumer to hand-write an ambientdeclare module '@upupjs/next/styles'shim.Hit in production use: DevinoSolutions/GetItDone's TS 6.0.3 upgrade needed a local
upup-styles.d.tsworkaround for exactly this (verified against@upupjs/next/@upupjs/core3.1.0, 2026-08-14).Fix options
allowArbitraryExtensions-style declaration (TS-official mechanism): shipdist/tailwind-prefixed.d.css.tsnext to the CSS and add atypescondition:declare module '@upupjs/next/styles';) shipped in dist and referenced by atypescondition.Either removes the consumer-side shim with no runtime change. Worth sweeping every framework package (
react,vue,svelte,vanilla,angular,preact,next) that exposes a CSS subpath the same way.