Skip to content

Add sideEffects field to zone.js/package.json #38939

@johncrim

Description

@johncrim

🚀 feature request

Relevant Package

zone.js

Description

zone.js is missing a sideEffects field in its package.json. I realize it's pretty side-effect-ful, which is probably why the field wasn't added, but I would think it would benefit optimization to have the sideEffects files clearly marked.

Describe the solution you'd like

Please consider adding a correct sideEffects field to zone.js/package.json, or explain why it's not necessary or a bad idea.

From https://angular.io/guide/ivy-compatibility :

Check that imported libraries have been marked side-effect-free. If your app imports from shared libraries that are meant to be free from side effects, add "sideEffects": false to their package.json. This will ensure that the libraries will be properly tree-shaken if they are imported but not directly referenced. See more details in the original issue here.

Metadata

Metadata

Assignees

Labels

P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: zonesIssues related to zone.js

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions