Error when transpiling using Rollupjs
See original GitHub issueI’m attempting to import newrelic using rollupjs as a transpiler.
import 'newrelic'
TypeError [ERR_INVALID_ARG_TYPE]: The "superCtor" argument must be of type function. Received undefined
at new NodeError (node:internal/errors:278:15)
at inherits (node:util:158:11)
at Object.<anonymous> (/path/to/mypackage.js:100637:1)
at Module._compile (node:internal/modules/cjs/loader:1108:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1137:10)
at Module.load (node:internal/modules/cjs/loader:973:32)
at Function.Module._load (node:internal/modules/cjs/loader:813:14)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:76:12)
at node:internal/main/run_main_module:17:47 {
code: 'ERR_INVALID_ARG_TYPE'
}
Issue Analytics
- State:
- Created 3 years ago
- Comments:14 (7 by maintainers)
Top Results From Across the Web
Babel / Rollup errors transpiling and bundling ES2017
I'm getting an error transpiling ES2017 JavaScript (specifically async/await functions) into ES5 using Rollup and Babel:.
Read more >@rollup/plugin-commonjs - npm
Start using @rollup/plugin-commonjs in your project by running `npm i ... that non-JavaScript files are transpiled by another plugin first.
Read more >rollup.js
Using this option will make Rollup transpile your configuration file to an ES ... Exit the build with an error if any warnings...
Read more >3 Options to Compile Typescript to JS: Rollup, TSC, Babel
Setting up Rollup is slick with a simple rollup.config.js file. ... avoid the Linting error: error TS2307: Cannot find module 'moduleA'.
Read more >An Introduction to the Rollup.js JavaScript Bundler - SitePoint
The examples below specifically use npx rollup , since it will work ... it easier to set breakpoints or locate problems when errors...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@btakita OK, gotcha. Yeah, the
node -r
thing will not work in that situation. I’ll bring this up with our team and try to get rollup support prioritized.I’m also noticing some circular dependencies. I’m using sapper 0.28.10, rollup ^2.36.1, pnpm 5.15.0, nodejs 15.5.1