Tom-Bonnike/netlify-plugin-inline-critical-css

Error when loading the plugin

Closed this issue · 2 comments

The following error happened 2 hours ago in a build:

Could not import plugin:
Unexpected token { 
    vm.js:80:10 createScript
    vm.js:139:10 Object.runInThisContext
    module.js:617:28 Module._compile
    module.js:664:10 Object.Module._extensions..js
    module.js:566:32 Module.load
    module.js:506:12 tryModuleLoad
    module.js:498:3 Function.Module._load
    module.js:597:17 Module.require
    internal/module.js:11:18 require
    /opt/build/repo/node_modules/fs-extra/lib/mkdirs/index.js:3:44 Object.<anonymous>

I am guessing this probably was triggered by you @Tom-Bonnike, but I just wanted to let you in case this was an unresolved bug. Thanks!

Yes, it’s because of the node version like I mentioned in netlify/plugins#30 (comment). Switching the node version fixed it :)

Oh yes. That's definitely a very hard to debug error message. I hope we can print better warnings using engines.node soon.