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
  • 657
  • 6
  • 21

1 Answers1

1

You can use

export { default as users } from './users';
//       ^^^^^^^ or whatever the module exports
Bergi
  • 630,263
  • 148
  • 957
  • 1,375