Export an imported module

// inner/mod.js
export function myFunc() {
   // ...
}

// mod.js
import { myFunc } from "./inner/mod";
export { myFunc };

Try to be explicit in what you import, the less the better, because of that I've changed your import in mod.js. If you do import *, you define a variable which will be the object of all names exports from that module you imported.

re-exporting is the same as making something of your own and exporting.


I believe what you are looking for is

export * from './inner/mod';

That will reexports all exports of ./inner/mod. The spec actually has very nice tables listing all the possible import and export variants.