First, remove the file extension from the
main entry in the
js file is CommonJS module.
mjs file is
ES module. This is for node's experimental support of ES module.
module entry (ref: pkg.module). The value is the ES module file.
And I suggest not use the mjs file directly. Copy the
.mjs file, rename it and
js as its file extension. This is for bundle tool.
jsnext:main is used by webpack 2.