Is there a JavaScript test coverage tool that supports ECMAScript/JavaScript modules?
You need the .mjs extension to make Node.js actually run it as a module (as opposed to a classic script). You can verify this with something like: console.log(this === undefined ? 'module' : 'classic script'); Save as foo.js and foo.mjs, and then run your command for each file.
-
-
yes, thank you, I forgot to mention, that I have `type: "module"` in the package.json
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
JavaScript, HTML, CSS, HTTP, performance, security, Bash, Unicode, i18n, macOS.