Closed slavafomin closed 4 years ago
It is a common convention for Rollup plugins: https://rollupjs.org/guide/en/#conventions
A plugin prefixes the path of a virtual (i.e. non-existing) module that other plugins "should not mess with" (like transforming the code) with a null character. Plugins should adhere to this rule and ignore ids that start with a null character unless they created them.
I'm running into this issue with the same error message. Is there a known workaround?
@jwvance Could you show you config?
Hey folks (this is a canned reply, but we mean it!). Thanks to everyone who participated in this issue. We're getting ready to move this plugin to a new home at https://github.com/rollup/plugins, and we have to do some spring cleaning of the issues to make that happen. We're going to close this one, but it doesn't mean that it's not still valid.
We've got some time yet before the move while we resolve pending Pull Requests, so if this issue is still relevant, please @ me and I'll make sure it gets reopened and transferred to the new repo. :beer:
Hello!
Thank you for this great plugin!
However, after adding it to our Rollup configuration, the build started to fail with the following error:
TypeError [ERR_INVALID_ARG_VALUE]: The argument 'path' must be a string or Uint8Array without null bytes. Received '…/node_modules/\u0000commonjsHelpers.js'
Looking at the source files of the plugin, I can see module names like this:
var HELPERS_ID = '\0commonjsHelpers.js';
.I believe, the problem is with
\0
(\u0000
) character in module ID. Why are you using it in the first place?Thanks!