phantomas
phantomas copied to clipboard
analyzeCss.js: lazy load analyze-css module via await import()
Prepare for analyze-css
to be a pure ESM package - https://github.com/macbre/analyze-css/issues/616
https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c - nice notes from @sindresorhus.
You need to run with a version of node that supports ES Modules in the VM API. See https://jestjs.io/docs/ecmascript-modules
Now that's interesting ...
$ npm t
(...)
Segmentation fault (core dumped)
npm ERR! Test failed. See above for more details.