0

I've the following statement:

exports.users = require("./users.js");

How can I convert that in a statement using the import/export notation defined in EcmaScript6?

misleadingTitle
  • 659
  • 6
  • 20

1 Answers1

1

You can use

export { default as users } from './users';
//       ^^^^^^^ or whatever the module exports
Bergi
  • 572,313
  • 128
  • 898
  • 1,281