With RequireJS, you can do something like:
define(['a', 'b', 'c'], function(a, b, c) {
console.log(arguments);
}
Is it possible to do something similar for an ES6 module? Ex:
import a from 'a.js';
import b from 'b.js';
import c from 'c.js';
console.log(imported_objects); // should console log the values of a, b, and c
I’m asking because I’m working on a project that transforms AMD code to ES6 modules. When I do the transform, arguments
is undefined because we’re no longer inside of a function, but I need to be able to do something similar in ES6. I’m guessing this isn’t possible because these are static imports? Thanks for any help