webWorkerTsConfig not working
muhamedkarajic opened this issue · comments
Current Behavior
I have been switching to esbuild and got my application into the state to compile and run. However when its built I end up in JIT compiler issue.
Expected Behavior
I expected it to just work. Very weird that its working in the serve process but that its not working in the other build.
GitHub Repo
No response
Steps to Reproduce
Below the project.json
{
"name": "SOME_CLIENT",
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"projectType": "application",
"prefix": "app",
"sourceRoot": "apps/SOME_CLIENT/src",
"tags": [],
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:application",
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/apps/SOME_CLIENT",
"index": "apps/SOME_CLIENT/src/index.html",
"browser": "apps/SOME_CLIENT/src/main.ts",
"polyfills": ["zone.js", "@angular/localize/init"],
"tsConfig": "apps/SOME_CLIENT/tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
"apps/SOME_CLIENT/src/favicon.ico",
"apps/SOME_CLIENT/src/assets",
"apps/SOME_CLIENT/src/manifest.webmanifest"
],
"styles": ["apps/SOME_CLIENT/src/styles.scss"],
"scripts": ["node_modules/jquery/dist/jquery.min.js"],
"webWorkerTsConfig": "apps/SOME_CLIENT/tsconfig.worker.json"
},
"configurations": {
"production": {
"budgets": [
{
"type": "initial",
"maximumWarning": "500kb"
},
{
"type": "anyComponentStyle",
"maximumWarning": "2kb"
}
],
"outputHashing": "all"
},
"development": {
"optimization": false,
"extractLicenses": false,
"sourceMap": true
}
},
"defaultConfiguration": "production"
},
"serve": {
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"buildTarget": "SOME_CLIENT:build:production"
},
"development": {
"buildTarget": "SOME_CLIENT:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
"buildTarget": "SOME_CLIENT:build"
}
},
"lint": {
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/SOME_CLIENT/**/*.ts", "apps/SOME_CLIENT/**/*.html"]
}
},
"test": {
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
"jestConfig": "apps/SOME_CLIENT/jest.config.ts",
"webWorkerTsConfig": "apps/SOME_CLIENT/tsconfig.worker.json"
}
},
"serve-static": {
"executor": "@nx/web:file-server",
"options": {
"buildTarget": "SOME_CLIENT:build",
"staticFilePath": "dist/apps/SOME_CLIENT/browser"
}
}
}
}
Nx Report
Node : 18.20.0
OS : darwin-arm64
npm : 10.5.0
nx : 19.3.1
@nx/js : 19.3.1
@nx/jest : 19.3.1
@nx/linter : 19.3.1
@nx/eslint : 19.3.1
@nx/workspace : 19.3.1
@nx/angular : 19.3.1
@nx/cypress : 19.3.1
@nx/devkit : 19.3.1
@nx/eslint-plugin : 19.3.1
@nrwl/tao : 19.3.1
@nx/web : 19.3.1
@nx/webpack : 19.3.1
typescript : 5.4.5
---------------------------------------
Registered Plugins:
@nx/cypress/plugin
@nx/eslint/plugin
Failure Logs
No response
Package Manager Version
No response
Operating System
- macOS
- Linux
- Windows
- Other (Please specify)
Additional Information
I have also tried package.json with:
"build": {
"executor": "@nx/angular:browser-esbuild" and
}
"serve": {
"executor": "@nx/angular:dev-server",
}
but then on npm run serve
it shows me a warrning that its not supposed so I went with the angular compiler, as recomended in #26669, and now ended up with the same issue.
@Coly010 please help!
@alan-agius4
Can you check this? Its related to angular/angular-cli#25101
Hey @muhamedkarajic !
I can see you're using the builders from the Angular devkit.
In this case, it's very unlikely that the issue lies with Nx as it is the Angular builder's that are invoked. Not Nx.
It would be worth raising an issue on the Angular CLI repo.
Hey @muhamedkarajic !
I can see you're using the builders from the Angular devkit. In this case, it's very unlikely that the issue lies with Nx as it is the Angular builder's that are invoked. Not Nx.
It would be worth raising an issue on the Angular CLI repo.
I wrote just there that I tried Nx things as well and it did not work. It shows me a warrning, dose anyone know why by Nx it shows that warrning?
Hm I found this: angular/angular-cli#28078
Will see next work week to get a look at it. Sorry @Coly010 after all looks like Angular issue.
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.