Unable to use JS decorators in private methods with the development build #30139
Labels
area: @angular/build
freq1: low
Only reported by a handful of users who observe it rarely
severity5: regression
type: bug/fix
Command
build
Is this a regression?
The previous version in which this bug was not present was
19.2.6
Description
When building with the default development configuration, if one is using JS decorators in a private method (not the experimental ones from TypeScript,
experimentalDecorators: false
) gets the following error:If the method is public, the error doesn't happen.
This error doesn't happen in version 19.2.6.
Minimal Reproduction
Reproduction url: https://github.com/jordimarimon/angular-cli-js-decorator
The application has been created using the following command:
There are only two additional files:
src/app/app.service.ts
src/app/debounce.ts
Run the command
npx ng build --configuration=production
and there shouldn't be any error.Now run the command
npx ng build --configuration=development
and there should be an error.If you downgrade to version
19.2.6
both commands run without any error.Exception or Error
Your Environment
Anything else relevant?
No response
The text was updated successfully, but these errors were encountered: