Skip to content

🐛 Fix yarn prod for current Angular version#746

Merged
kevin-atnos merged 1 commit intoLINCnil:masterfrom
busser:arthur/fix-prod-build
Jan 29, 2024
Merged

🐛 Fix yarn prod for current Angular version#746
kevin-atnos merged 1 commit intoLINCnil:masterfrom
busser:arthur/fix-prod-build

Conversation

@busser
Copy link
Copy Markdown
Contributor

@busser busser commented Jan 25, 2024

It seems that since the project updated to a newer version of Angular, the
production build doesn't work anymore. I tracked the issue down to the
src/environments/environment.prod.ts file, which wasn't updated to match the
src/environments/environment.ts file.

Before the fix, yarn prod fails with this error:

./src/environments/environment.ts:5:11-30 - Error: Should not import the named export 'version' (imported as 'packageJson') from default-exporting module (only default export is available soon)

After the fix, yarn prod succeeds.

It seems that since the project updated to a newer version of Angular, the
production build doesn't work anymore. I tracked the issue down to the
`src/environments/environment.prod.ts` file, which wasn't updated to match the
`src/environments/environment.ts` file.

Before the fix, `yarn prod` fails with this error:

```
./src/environments/environment.ts:5:11-30 - Error: Should not import the named export 'version' (imported as 'packageJson') from default-exporting module (only default export is available soon)
```

After the fix, `yarn prod` succeeds.
@kevin-atnos kevin-atnos requested a review from syl-p January 26, 2024 12:59
@kevin-atnos
Copy link
Copy Markdown
Collaborator

Hello!

Indeed we have noticed this issue too.
Thank you for your contribution, we are merging it right now!

Regards,

@kevin-atnos kevin-atnos self-requested a review January 29, 2024 15:50
@kevin-atnos kevin-atnos merged commit 01cc74e into LINCnil:master Jan 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants