Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Included as stated in readme but I get TypeError: cannot read proprty length of undefined #2

Open
SumNeuron opened this issue May 7, 2018 · 1 comment

Comments

@SumNeuron
Copy link

Tried to include this in the tutorial from https://code.lengstorf.com/learn-rollup-js/ and got TypeError...

@sgnagnarella
Copy link

sgnagnarella commented Dec 13, 2018

I am getting a similar error when turning on source maps.
This is my rollup.js file

`
import commonjs from "rollup-plugin-commonjs";
import obfuscatorPlugin from "rollup-plugin-javascript-obfuscator";

export default {
input: "src/main.js",
output: {
file: "build/main.js",
format: "cjs",
name: "fwi"
},
sourceMap: true,
sourceMapMode: "inline",
plugins: [
commonjs({
include: "node_modules/**"
}),
obfuscatorPlugin({
compact: true
})
]
};
`

And this is the error I get:

[!] TypeError: Cannot read property 'length' of undefined TypeError: Cannot read property 'length' of undefined at Link.traceMappings (/Users/sgnagnarella/Documents/SourceCode/pcshim/node_modules/rollup/dist/rollup.js:13559:54) at collapseSourcemaps (/Users/sgnagnarella/Documents/SourceCode/pcshim/node_modules/rollup/dist/rollup.js:13680:21) at /Users/sgnagnarella/Documents/SourceCode/pcshim/node_modules/rollup/dist/rollup.js:14946:27 at process._tickCallback (internal/process/next_tick.js:68:7) at Function.Module.runMain (internal/modules/cjs/loader.js:744:11) at startup (internal/bootstrap/node.js:285:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:739:3)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants