cli question
are we required to use commonjs module from CLI example ? (its like that in package.json) and what whill happen if i change it to module
Solution:Jump to solution
Required: no
What will happen: the same as with converting anything CJS to ESM. You'll have to update your imports to have extensions or use import mapping and you can't use require,
__dirname
, __filename
and some other globals anymore. See https://nodejs.org/api/esm.html...1 Reply
Solution
Required: no
What will happen: the same as with converting anything CJS to ESM. You'll have to update your imports to have extensions or use import mapping and you can't use require,
__dirname
, __filename
and some other globals anymore. See https://nodejs.org/api/esm.html