package.json
{
"name": " bada",
"exports": {
"./boom": "./lib/powder.mjs"
}
}
index.mjs
Will throw with the error
Error: Cannot find package '$PACAKGE_NAME' imported from ...
Adding a dot export to the package.json makes thing work as expected
package.json
```json
{
"name": " bada",
"exports": {
".": "./ohnoes.lol",
"./boom": "./lib/powder.mjs"
}
}
Seems like this might be to spec (as currently written). I'm not sure that we want to enforce a "." main if folks don't need one (thinking about top level application), but at the very least we likely want to throw with a better error... lost some time debugging this.
package.json
{ "name": " bada", "exports": { "./boom": "./lib/powder.mjs" } }index.mjs
Will throw with the error
Adding a dot export to the package.json makes thing work as expected
Seems like this might be to spec (as currently written). I'm not sure that we want to enforce a "." main if folks don't need one (thinking about top level application), but at the very least we likely want to throw with a better error... lost some time debugging this.