Open
Description
This relates to:
- refactor: build native ESM #98
- fix(deps): ESM deps should be dev-only #100
- type: 'module' or format: 'esm' should not require dependencies ipfs/aegir#1104
- type: 'module' or format: 'esm' should generate esm modules ipfs/aegir#1096
The way we're generating ESM right now transpiles src into ESM which exports the required interfaces for performing geo-ip lookups. This works well for all agents that support module
types and allows import/export syntax (e.g. browsers, node, etc) (except for the dependency issues in #100).
However, this takes away the ability to tree-shake the module when ipfs-geoip
is included as a dependency to say ipfs-webui
because we're unable to bundle this properly. e.g. https://github.com/ipfs-shipyard/ipfs-geoip/actions/runs/3287072521/jobs/5415859864#step:5:124
AI:
- Cleanup Configs to build ESM valid in both Node-like and browser context
- Establish imports are tree-shakeable
- Setup better defaults to check this in aegir.
Metadata
Metadata
Assignees
Labels
No labels