diff options
Diffstat (limited to 'activestorage/rollup.config.js')
-rw-r--r-- | activestorage/rollup.config.js | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/activestorage/rollup.config.js b/activestorage/rollup.config.js new file mode 100644 index 0000000000..1b4f9477ab --- /dev/null +++ b/activestorage/rollup.config.js @@ -0,0 +1,28 @@ +import resolve from "rollup-plugin-node-resolve" +import commonjs from "rollup-plugin-commonjs" +import babel from "rollup-plugin-babel" +import uglify from "rollup-plugin-uglify" + +const uglifyOptions = { + mangle: false, + compress: false, + output: { + beautify: true, + indent_level: 2 + } +} + +export default { + input: "app/javascript/activestorage/index.js", + output: { + file: "app/assets/javascripts/activestorage.js", + format: "umd", + name: "ActiveStorage" + }, + plugins: [ + resolve(), + commonjs(), + babel(), + uglify(uglifyOptions) + ] +} |