I have seen other similar questions. The questions I have seen were asked before the release of Webpack 4, did not ask specifically about npm, and were not definitively answered.
Let's say I use webpack to bundle a package that includes dependencies, and I don't want to categorize these dependencies as webpack externals and npm peer dependencies. I then publish this package to npm.
Someone downloads my package and uses it as part of a project. That project already includes one of my package's dependencies. Let's say this project is, in turn, bundled by webpack.
1.) Will webpack recognize and dedupe the duplicate dependencies when the project is bundled?
2.) If not, and if I don't use webpack to bundle my npm package, would it allow webpack to dedupe the duplicate dependencies when the project is bundled?
3.) What are best practices along these lines?