I want to release a NPM package and I am currently looking for a solution to give users the option to use my rollup bundled ES5 code, or use the ES6 version.
I have a subfolder called lib
where I have a index.js
and another subfolder inside it called es6
which also has a index.js
In my package.json
I have specified the main file as ./lib/index.js
How can I now make it possible to import the ES6 file by using import * as package from "package/es6"
or is that not possible at all? If not, how would you import it?