Skip to content
This repository has been archived by the owner on Apr 28, 2020. It is now read-only.

Commit

Permalink
Use rollup to bundle JS, run babel through rollup
Browse files Browse the repository at this point in the history
  • Loading branch information
yellowled committed Jul 30, 2019
1 parent 8c8cf6e commit 75248ed
Show file tree
Hide file tree
Showing 5 changed files with 327 additions and 198 deletions.
3 changes: 3 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,8 @@
"quotes": ["error", "single"],
"semi": ["error", "always"],
"compat/compat": "error"
},
"parserOptions": {
"sourceType": "module"
}
}
19 changes: 19 additions & 0 deletions .rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import resolve from 'rollup-plugin-node-resolve';
import commonjs from 'rollup-plugin-commonjs';
import babel from 'rollup-plugin-babel';

export default {
input: 'src/scripts/index.js',
output: {
file: 'src/js/main.js',
format: 'iife',
sourcemap: true,
},
plugins: [
resolve(),
commonjs(),
babel({
exclude: ['node_modules/**'],
}),
],
};
Loading

0 comments on commit 75248ed

Please sign in to comment.