developit / microbundle

📦 Zero-configuration bundler for tiny modules.
https://npm.im/microbundle
MIT License
8k stars 361 forks source link

No name was provided for external module for global packages #1004

Closed schettn closed 11 months ago

schettn commented 1 year ago
    Encountering this issue I have been wondering why with scoped npm packages this warning appears and  with non-scoped npm packages not.

I found that scoped packages don't pass the following check: https://github.com/developit/microbundle/blob/fa3eac6f491288ff3b8cfd2812eecd350c7a2316/src/index.js#L337

Curious if this is intented.

Originally posted by @namjul in https://github.com/developit/microbundle/issues/223#issuecomment-788889113

rschristian commented 1 year ago

Scoped packages are harder to guess. For instance:

Both use cases are very popular, so I tend to think there's too much ambiguity there to "take a side" and set one as the default behavior. Just my 2¢

rschristian commented 11 months ago

Going to close this out, hopefully its been answered.