jkrems / proposal-pkg-exports

Proposal for Bare Module Specifier Resolution in node.js
MIT License
129 stars 14 forks source link

Error handling #28

Open zenparsing opened 5 years ago

zenparsing commented 5 years ago

Import maps fail-soft with console warnings. Like import maps, export maps have a fairly restrictive syntax for both keys and values. What should node do when it encounters an invalid key or value?

jkrems commented 5 years ago

I assume we would generally follow precedent set by import maps. There's currently discussions around making export maps work for providing different entrypoints depending on platform (e.g. modern browser, node 6+, etc.) which may force us to go with "ignore invalid entries" to some degree.