diff --git a/apps/web-tss/tsconfig.json b/apps/web-tss/tsconfig.json index 3fec530fd..1fdef9a8d 100644 --- a/apps/web-tss/tsconfig.json +++ b/apps/web-tss/tsconfig.json @@ -2,7 +2,8 @@ "$schema": "https://json.schemastore.org/tsconfig", "include": [ "src/**/*.ts", - "src/**/*.tsx" + "src/**/*.tsx", + "node_modules/vite/client.d.ts" ], "exclude": ["node_modules", "dist", "**/*.stories.ts", "**/*.stories.tsx"], "compilerOptions": { @@ -10,7 +11,7 @@ "jsx": "react-jsx", "module": "ESNext", "lib": ["ES2022", "DOM", "DOM.Iterable"], - "types": ["vite/client"], + "typeRoots": ["./node_modules/@types"], "moduleResolution": "bundler", "allowImportingTsExtensions": true, @@ -24,7 +25,8 @@ "noUncheckedSideEffectImports": true, "baseUrl": ".", "paths": { - "@/*": ["./src/*"] + "@/*": ["./src/*"], + "vite/client": ["./node_modules/vite/client.d.ts"] } }, "references": [ diff --git a/apps/web-tss/vite.config.ts b/apps/web-tss/vite.config.ts index 9aefb4bc6..9b95c2d33 100644 --- a/apps/web-tss/vite.config.ts +++ b/apps/web-tss/vite.config.ts @@ -5,27 +5,29 @@ import { defineConfig } from 'vite'; import checker from 'vite-plugin-checker'; import viteTsConfigPaths from 'vite-tsconfig-paths'; -const config = defineConfig({ - server: { - port: 3000, - }, - plugins: [ - // this is the plugin that enables path aliases - viteTsConfigPaths({ - projects: ['./tsconfig.json'], - }), - tailwindcss(), - tanstackStart({ - customViteReactPlugin: true, - }), - viteReact(), - !process.env.VITEST - ? checker({ - typescript: true, - biome: true, - }) - : undefined, - ], -}); +export default defineConfig(({ command }) => { + const isServe = command === 'serve'; -export default config; + return { + server: { + port: 3000, + }, + plugins: [ + // this is the plugin that enables path aliases + viteTsConfigPaths({ + projects: ['./tsconfig.json'], + }), + tailwindcss(), + tanstackStart({ + customViteReactPlugin: true, + }), + viteReact(), + isServe + ? checker({ + typescript: true, + biome: true, + }) + : undefined, + ], + }; +}); diff --git a/package.json b/package.json index 00692207b..ae286841c 100644 --- a/package.json +++ b/package.json @@ -64,6 +64,12 @@ "packageManager": "pnpm@9.15.0", "pnpm": { "overrides": { + "@buster-app/web>react": "18.3.1", + "@buster-app/web>react-dom": "18.3.1", + "@buster-app/web>@types/react": "^18.3.23", + "@buster-app/web>@types/react-dom": "^18.3.7", + "@buster-app/web-tss>react": "^19.1.1", + "@buster-app/web-tss>react-dom": "^19.1.1", "@buster-app/web-tss>@types/react": "^19.1.10", "@buster-app/web-tss>@types/react-dom": "^19.1.7" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 1c1888689..af0de232f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -110,6 +110,12 @@ catalogs: version: 3.25.76 overrides: + '@buster-app/web>react': 18.3.1 + '@buster-app/web>react-dom': 18.3.1 + '@buster-app/web>@types/react': ^18.3.23 + '@buster-app/web>@types/react-dom': ^18.3.7 + '@buster-app/web-tss>react': ^19.1.1 + '@buster-app/web-tss>react-dom': ^19.1.1 '@buster-app/web-tss>@types/react': ^19.1.10 '@buster-app/web-tss>@types/react-dom': ^19.1.7 @@ -635,7 +641,7 @@ importers: specifier: ^1.259.0 version: 1.259.0 react: - specifier: ^18.3.1 + specifier: 18.3.1 version: 18.3.1 react-color: specifier: ^2.19.3 @@ -653,7 +659,7 @@ importers: specifier: ^16.0.1 version: 16.0.1 react-dom: - specifier: ^18.3.1 + specifier: 18.3.1 version: 18.3.1(react@18.3.1) react-hotkeys-hook: specifier: ^5.1.0 @@ -17274,11 +17280,11 @@ snapshots: zod-from-json-schema: 0.0.5 zod-to-json-schema: 3.24.6(zod@3.25.76) - '@mdx-js/react@3.1.0(@types/react@18.3.23)(react@18.3.1)': + '@mdx-js/react@3.1.0(@types/react@18.3.23)(react@19.1.1)': dependencies: '@types/mdx': 2.0.13 '@types/react': 18.3.23 - react: 18.3.1 + react: 19.1.1 '@mdx-js/react@3.1.0(@types/react@19.1.10)(react@19.1.1)': dependencies: @@ -20590,12 +20596,12 @@ snapshots: '@storybook/addon-docs@9.1.1(@types/react@18.3.23)(storybook@9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)))': dependencies: - '@mdx-js/react': 3.1.0(@types/react@18.3.23)(react@18.3.1) + '@mdx-js/react': 3.1.0(@types/react@18.3.23)(react@19.1.1) '@storybook/csf-plugin': 9.1.1(storybook@9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0))) - '@storybook/icons': 1.4.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1) - '@storybook/react-dom-shim': 9.1.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(storybook@9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0))) - react: 18.3.1 - react-dom: 18.3.1(react@18.3.1) + '@storybook/icons': 1.4.0(react-dom@19.1.1(react@19.1.1))(react@19.1.1) + '@storybook/react-dom-shim': 9.1.1(react-dom@19.1.1(react@19.1.1))(react@19.1.1)(storybook@9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0))) + react: 19.1.1 + react-dom: 19.1.1(react@19.1.1) storybook: 9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)) ts-dedent: 2.2.0 transitivePeerDependencies: @@ -20680,11 +20686,6 @@ snapshots: '@storybook/global@5.0.0': {} - '@storybook/icons@1.4.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': - dependencies: - react: 18.3.1 - react-dom: 18.3.1(react@18.3.1) - '@storybook/icons@1.4.0(react-dom@19.1.1(react@19.1.1))(react@19.1.1)': dependencies: react: 19.1.1 @@ -20794,6 +20795,12 @@ snapshots: react-dom: 18.3.1(react@18.3.1) storybook: 9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)) + '@storybook/react-dom-shim@9.1.1(react-dom@19.1.1(react@19.1.1))(react@19.1.1)(storybook@9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)))': + dependencies: + react: 19.1.1 + react-dom: 19.1.1(react@19.1.1) + storybook: 9.1.1(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)) + '@storybook/react-dom-shim@9.1.2(react-dom@19.1.1(react@19.1.1))(react@19.1.1)(storybook@9.1.2(@testing-library/dom@10.4.1)(msw@2.10.4(@types/node@24.0.10)(typescript@5.9.2))(prettier@3.6.2)(vite@7.1.2(@types/node@24.0.10)(jiti@2.5.1)(lightningcss@1.30.1)(sass@1.90.0)(terser@5.43.1)(tsx@4.20.3)(yaml@2.8.0)))': dependencies: react: 19.1.1 @@ -24707,8 +24714,8 @@ snapshots: '@typescript-eslint/parser': 8.35.1(eslint@8.57.1)(typescript@5.9.2) eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1) - eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1))(eslint@8.57.1) + eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.32.0)(eslint@8.57.1) + eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1) eslint-plugin-jsx-a11y: 6.10.2(eslint@8.57.1) eslint-plugin-react: 7.37.5(eslint@8.57.1) eslint-plugin-react-hooks: 5.2.0(eslint@8.57.1) @@ -24731,7 +24738,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1): + eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0)(eslint@8.57.1): dependencies: '@nolyfill/is-core-module': 1.0.39 debug: 4.4.1 @@ -24742,22 +24749,22 @@ snapshots: tinyglobby: 0.2.14 unrs-resolver: 1.11.0 optionalDependencies: - eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1))(eslint@8.57.1) + eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1) transitivePeerDependencies: - supports-color - eslint-module-utils@2.12.1(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1))(eslint@8.57.1): + eslint-module-utils@2.12.1(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1): dependencies: debug: 3.2.7 optionalDependencies: '@typescript-eslint/parser': 8.35.1(eslint@8.57.1)(typescript@5.9.2) eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1) + eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.32.0)(eslint@8.57.1) transitivePeerDependencies: - supports-color - eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1))(eslint@8.57.1): + eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.9 @@ -24768,7 +24775,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.12.1(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint@8.57.1))(eslint@8.57.1))(eslint@8.57.1) + eslint-module-utils: 2.12.1(@typescript-eslint/parser@8.35.1(eslint@8.57.1)(typescript@5.9.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.10.1)(eslint@8.57.1) hasown: 2.0.2 is-core-module: 2.16.1 is-glob: 4.0.3