I would like to write a JavaScript library using ES6 modules to manage submodules. I would also like to be able to use it in both front-end applications (with babel and webpack) and NodeJS back-end projects.
Is there a way to "build" the library, written with ES6 modules, in order to use it also as a NodeJS library?