Advertisement
jcho0k

Untitled

Jun 14th, 2017
511
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import babel from 'rollup-plugin-babel'
  2. import json from 'rollup-plugin-json'
  3. import resolve from 'rollup-plugin-node-resolve'
  4. import commonjs from 'rollup-plugin-commonjs'
  5. import replace from 'rollup-plugin-replace'
  6. import stylusCssModules from 'rollup-plugin-stylus-css-modules'
  7. import builtins from 'rollup-plugin-node-builtins'
  8. import filesize from 'rollup-plugin-filesize'
  9. import progress from 'rollup-plugin-progress'
  10. import globals from 'rollup-plugin-node-globals'
  11.  
  12. const main = process.env.npm_package_main
  13.  
  14. export default {
  15.   entry: main,
  16.   format: 'iife',
  17.   plugins: [
  18.     replace({'process.env.NODE_ENV': JSON.stringify('development')}),
  19.     progress(),
  20.     stylusCssModules({output: false}),
  21.     json({preferConst: true}),
  22.     babel({
  23.       babelrc: false,
  24.       exclude: [
  25.         'node_modules/**',
  26.         'src/styles/**'
  27.       ],
  28.       presets: [['es2015', {modules: false}]],
  29.       plugins: ['external-helpers']
  30.     }),
  31.     builtins(),
  32.     resolve({
  33.       jsnext: true,
  34.       main: true,
  35.       module: true,
  36.       browser: true,
  37.       preferBuiltins: true
  38.     }),
  39.     commonjs({
  40.       include: 'node_modules/**',
  41.       ignoreGlobal: true
  42.     }),
  43.     globals(),
  44.     filesize()
  45.   ],
  46.   moduleName: 'videomail-client',
  47.   dest: 'dist/videomail-client.js',
  48.   sourceMap: 'inline'
  49. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement