ES6, how can you export an imported module in a single line?

前端 未结 6 628
梦毁少年i
梦毁少年i 2020-11-29 21:42

I\'d like to the following but with a single line, if possible:

  • import Module from \'./Module/Module;\'
  • export Module;
  • <
6条回答
  •  攒了一身酷
    2020-11-29 21:56

    Please note you can also re-export everything from a module:

    export * from './Module/Module';
    

提交回复
热议问题