-
-
Notifications
You must be signed in to change notification settings - Fork 604
Closed
Description
- Rollup Plugin Name: commonjs
- Rollup Plugin Version: 11.1.0
- Rollup Version: 2.7.3
- Operating System (or Browser): Windows 10 or ElectronJS (chromium)
- Node Version: 14.0.0
How Do We Reproduce?
- Clone https://github.com/Olyno/repro-rollup-issue
- Install dependencies (
npm i
) - Run App (
npm run dev
)
Expected Behavior
Should not compile require
syntax, but only es6 syntaxes (e.g import
, export
), or simply when we precise it to rollup. It should works fine with nodeIntegration
of ElectronJS. It worked fine before I did a upgrade latest
command, and now it doesn't work anymore.
Actual Behavior
In the console:
rollup v2.7.3
bundles src/main.js → public\build\bundle.js...
(!) Missing shims for Node.js built-ins
Creating a browser bundle that depends on 'path'. You might need to include https://www.npmjs.com/package/rollup-plugin-node-builtins
LiveReload enabled
(!) Unresolved dependencies
https://rollupjs.org/guide/en/#warning-treating-module-as-external-dependency
fs (imported by src\store.js, fs?commonjs-external)
path (imported by src\store.js, path?commonjs-external)
(!) Missing global variable names
Use output.globals to specify browser global variable names corresponding to external modules
fs (guessing 'fs')
path (guessing 'path')
created public\build\bundle.js in 321ms