by hzoo · 8y ago · 0 comments
Yeah it's mostly a conventional then we have to figure out.
Some people have different "dist" folders like say with redux_- https://unpkg.com/redux@3.7.2/ there is `src`, `lib`, `es`, `dist`.
In package.json, you can specify
"main": "lib/index.js",
"module": "es/index.js",
"jsnext:main": "es/index.js",
"typings": "./index.d.ts",
which a bundler like webpack will look at. The problem now mostly is that "module" assumes es modules but not a specific level of ES/polyfills and we want a way to do that instead. Making a yearly "es2015", "es2016" field seems weird and we want one that is up to date like preset-env?No comments yet.