fix: fix root start script (#5032)

Fixes #5022

See https://nx.dev/recipes/running-tasks/root-level-scripts#setup
This commit is contained in:
Thaïs
2024-04-19 18:28:02 +02:00
committed by GitHub
parent 43f0b11aab
commit d3170fc1ea
28 changed files with 94 additions and 79 deletions

View File

@ -7,7 +7,6 @@
"build": "npx vite build && sh ./scripts/inject-runtime-env.sh",
"build:sourcemaps": "VITE_BUILD_SOURCEMAP=true NODE_OPTIONS=--max-old-space-size=3000 npx nx build",
"start:prod": "NODE_ENV=production npx vite --host",
"storybook:build": "npx storybook build",
"tsup": "npx tsup"
},
"engines": {

View File

@ -29,10 +29,10 @@
"options": {
"cwd": "{projectRoot}",
"command": "tsc -b tsconfig.json",
"incremental": true
"args": ["--incremental"]
},
"configurations": {
"ci": { "incremental": false },
"ci": { "args": [] },
"watch": { "watch": true }
}
},
@ -91,6 +91,14 @@
"watch": { "watch": true }
}
},
"storybook:build": {
"executor": "@nx/storybook:build",
"outputs": ["{options.outputDir}"],
"options": {
"outputDir": "{projectRoot}/storybook-static",
"configDir": "{projectRoot}/.storybook"
}
},
"storybook:dev": {
"executor": "@nx/storybook:storybook",
"options": {
@ -102,8 +110,8 @@
"executor": "@nx/web:file-server",
"options": {
"buildTarget": "twenty-front:storybook:build",
"staticFilePath": "{projectRoot}/storybook-static",
"port": 6006,
"staticFilePath": "{projectRoot}/storybook-static",
"watch": false
}
},

View File

@ -0,0 +1,5 @@
import { ThemeType } from 'twenty-ui';
declare module '@emotion/react' {
export interface Theme extends ThemeType {}
}

View File

@ -21,7 +21,6 @@ import { DialogManagerScope } from '@/ui/feedback/dialog-manager/scopes/DialogMa
import { SnackBarProvider } from '@/ui/feedback/snack-bar-manager/components/SnackBarProvider';
import { SnackBarProviderScope } from '@/ui/feedback/snack-bar-manager/scopes/SnackBarProviderScope';
import { AppThemeProvider } from '@/ui/theme/components/AppThemeProvider';
import { ThemeType } from '@/ui/theme/constants/ThemeLight';
import { UserProvider } from '@/users/components/UserProvider';
import { UserProviderEffect } from '@/users/components/UserProviderEffect';
import { PageChangeEffect } from '~/effect-components/PageChangeEffect';
@ -82,7 +81,3 @@ root.render(
</AppErrorBoundary>
</RecoilRoot>,
);
declare module '@emotion/react' {
export interface Theme extends ThemeType {}
}

View File

@ -1,7 +1,6 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "../../dist/out-tsc",
"types": ["node"]
},
"exclude": [
@ -13,5 +12,11 @@
"**/*.test.ts",
"**/*.test.tsx"
],
"include": ["src/**/*.js", "src/**/*.jsx", "src/**/*.ts", "src/**/*.tsx"]
"include": [
"src/**/*.js",
"src/**/*.jsx",
"src/**/*.d.ts",
"src/**/*.ts",
"src/**/*.tsx"
]
}

View File

@ -19,6 +19,7 @@
"noUnusedParameters": false,
"noFallthroughCasesInSwitch": true,
"forceConsistentCasingInFileNames": true,
"outDir": "../../dist/out-tsc",
"paths": {
"@/*": ["packages/twenty-front/src/modules/*"],
"~/*": ["packages/twenty-front/src/*"],
@ -34,6 +35,9 @@
},
{
"path": "./tsconfig.spec.json"
},
{
"path": "./tsconfig.storybook.json"
}
],
"extends": "../../tsconfig.base.json"

View File

@ -1,19 +1,15 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "../../dist/out-tsc",
"types": ["jest", "node"]
},
"include": [
".storybook/**/*",
"**/__mocks__/**/*",
"jest.config.ts",
"setupTests.ts",
"src/**/*.d.ts",
"src/**/*.spec.ts",
"src/**/*.spec.tsx",
"src/**/*.stories.ts",
"src/**/*.stories.tsx",
"src/**/*.test.ts",
"src/**/*.test.tsx",
"tsup.config.ts",

View File

@ -0,0 +1,14 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"emitDecoratorMetadata": true
},
"include": [
".storybook/*.ts",
".storybook/*.tsx",
"src/**/*.d.ts",
"src/**/*.stories.mdx",
"src/**/*.stories.ts",
"src/**/*.stories.tsx"
]
}