lightscript / babel-preset-lightscript

0 stars 1 forks source link

LightScript & Rollup Issue #1

Open Darkle opened 7 years ago

Darkle commented 7 years ago

I'm having an issue using lightscript with rollup. Lightscript includes the babel-plugin-transform-es2015-modules-commonjs module, which rollup doesnt like: https://rollupjs.org/#babel. It'd be great if it were possible to disable this require if you dont want/need it.

I've created a sample repo to see the issue: https://github.com/Darkle/lightscript-rollup-test Just type npm install then npm start and the error will show up in the terminal:

index.lsc.js → index-compiled.js...
[!] (babel plugin) Error: It looks like your Babel configuration specifies a module transformer. Please disable it. See https://github.com/rollup/rollup-plugin-babel#configuring-babel for more information
index.lsc.js
Error: It looks like your Babel configuration specifies a module transformer. Please disable it. See https://github.com/rollup/rollup-plugin-babel#configuring-babel for more information
    at error (C:\Users\Coop\Coding\lightscript-rollup-test\node_modules\rollup\dist\rollup.js:185:14)
    at Object.error (C:\Users\Coop\Coding\lightscript-rollup-test\node_modules\rollup\dist\rollup.js:9407:6)
    at promise.then.previous (C:\Users\Coop\Coding\lightscript-rollup-test\node_modules\rollup\dist\rollup.js:9416:32)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)
    at Function.Module.runMain (module.js:667:11)
    at startup (bootstrap_node.js:187:16)
    at bootstrap_node.js:607:3

Cheers.

rattrayalex commented 7 years ago

Agreed, it should be possible to disable this.