I have a multi-file project, with ES6 style export
s and import
s.
I'm using Brunch to concatenate these files into 1 main.js
file that will serve as the main
for an NPM package.
To specify the API of my package, I need to have export
s in main.js
. But when Brunch concatenates my js
files, I am worried that (1) export
s that are meant for internal import
s and (2) export
s meant for my API will both look the same.
Looking at the generated main.js
file it seems like the export
s I write in my source code get wrapped into modules, but none of these are top-level exports like the ones needed for NPM packages.
How can I let NPM distinguish between these two types of export
s? Specifically, how can I have export
s in the main.js
file generated by Brunch concatenation?