developit / microbundle

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

Document usage of "-d" flag #861

Closed pm0u closed 3 years ago

pm0u commented 3 years ago

While running into some tree-shaking issues, I came across issue https://github.com/developit/microbundle/issues/457 which recommends using the -d flag to split output and use multiple input files.

I cannot find this flag/feature documented anywhere. How does this work and what is it's intended purpose?

pm0u commented 3 years ago

I see, it appears this is an alias of "--output" ? https://github.com/developit/microbundle/blob/master/src/prog.js#L92

if correct, feel free to close.. documentation would be nice though.

rschristian commented 3 years ago

Yep, that's all it is. Just kept around to ensure nothing breaks.

Do you think a notice on this comment https://github.com/developit/microbundle/issues/457#issuecomment-516116065 that -d is just an alias would be helpful?

pm0u commented 3 years ago

@rschristian I think that wouldn't hurt, or including it in the main CLI documentation in the README (the first place I went to)

rschristian commented 3 years ago

I don't think we want to document aliases which (as far as I can tell) exist only for legacy purposes.

I'll add a note to that comment, hopefully that might catch future issues.