Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep environment.ts a separate file when bundling for browser #227

Open
mensch72 opened this issue Nov 18, 2022 · 0 comments
Open

Keep environment.ts a separate file when bundling for browser #227

mensch72 opened this issue Nov 18, 2022 · 0 comments
Labels
angular Probably needs Angular-related skills feature A new feature or enhancement help wanted Extra attention is needed low priority not yet ready Not ready for implementation yet --> place in "Discussions"
Milestone

Comments

@mensch72
Copy link
Collaborator

When doing ionic build --prod, the file environment.ts (after being replaced by environment.prod.ts) gets minimized, uglified and bundled.

We should prevent this (if possible), so that environment.ts remains a separate, non-uglified file in the browser bundle.

(We still want the rest of the code to be optimized for production of course)

Rationale: We’d like to distribute the pre-built bundle to different server admins for installation on their servers, and they need to make local adjustments to environment.ts. I want to spare them the effort to do a local build only because they need to adjust one value in environment.ts.

Related Ionic forum question: https://forum.ionicframework.com/t/keep-environment-ts-a-separate-file-in-bundling-for-browser/228731

@mensch72 mensch72 added feature A new feature or enhancement help wanted Extra attention is needed low priority not yet ready Not ready for implementation yet --> place in "Discussions" angular Probably needs Angular-related skills labels Nov 18, 2022
@mensch72 mensch72 added this to the First Release milestone Nov 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
angular Probably needs Angular-related skills feature A new feature or enhancement help wanted Extra attention is needed low priority not yet ready Not ready for implementation yet --> place in "Discussions"
Projects
None yet
Development

No branches or pull requests

1 participant