(nuxt) do not typecheck on nuxt build in production (speeds up deployment and reduces memory usage)

move ts-node to dependencies as the cron jobs use this and yarn install in production env does not install dev dependencies
explicitely disable sentry when SENTRY_DSN is not set to prevent further warnings
This commit is contained in:
Valentyne Stigloher 2024-03-21 13:03:58 +01:00
parent ceb7d49c06
commit 0081afc24e
2 changed files with 4 additions and 5 deletions

View File

@ -178,10 +178,8 @@ const nuxtConfig: NuxtConfig = {
buildModules: [
'@nuxt/typescript-build',
],
loaders: {
ts: {
configFile: path.resolve(__dirname, 'tsconfig.json'),
},
typescript: {
typeCheck: process.env.NODE_ENV !== 'production',
},
modules: [
'@privyid/nuxt-csrf',
@ -220,6 +218,7 @@ const nuxtConfig: NuxtConfig = {
enableAutoPageviews: false,
},
sentry: {
disabled: !process.env.SENTRY_DSN,
tracing: {
tracesSampleRate: 0.1,
browserTracing: {

View File

@ -65,6 +65,7 @@
"sqlite": "^4.0.12",
"sqlite3": "^5.1.6",
"suml": "^0.2.2",
"ts-node": "^10.9.2",
"twitter": "^1.7.1",
"ulid": "^2.3.0",
"uuid": "^8.3.2",
@ -130,7 +131,6 @@
"suml-loader": "^0.1.1",
"ts-jest": "^29.1.1",
"ts-json-schema-generator": "^1.5.0",
"ts-node": "^10.9.2",
"typescript": "^5.3.3",
"vue-tsc": "^1.8.27",
"webpack": "^4.47.0",