Advertisement
bennyp

Untitled

Oct 30th, 2017
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import sourcemaps from 'rollup-plugin-sourcemaps';
  2. import resolve from 'rollup-plugin-node-resolve';
  3. import builtins from 'rollup-plugin-node-builtins';
  4. import globals from 'rollup-plugin-node-globals';
  5. import commonjs from 'rollup-plugin-commonjs';
  6. import json from 'rollup-plugin-json';
  7.  
  8. export default {
  9.  
  10.   cache: null,
  11.  
  12.   external: [
  13.     'aws-sdk',
  14.     'amazon-cognito-identity-id',
  15.   ],
  16.  
  17.   globals: {
  18.     'aws-sdk': 'AWS',
  19.   },
  20.  
  21.   paths: {
  22.     'aws-sdk': 'node_modules/aws-sdk-js/dist/aws-sdk.js',
  23.     // eslint-disable-next-line max-len
  24.     'amazon-cognito-identity-id': 'node_modules/amazon-cognito-identity-id/dist/amazon-cognito-identity-id.js',
  25.   },
  26.  
  27.   input: 'src/eve-redux/eve-redux-store.js',
  28.  
  29.   output: {
  30.     file: 'src/bundle.js',
  31.     name: 'EVE',
  32.     format: 'iife',
  33.   },
  34.  
  35.   watch: {
  36.     include: 'src/**/*.js',
  37.     exclude: 'src/**/*.html',
  38.   },
  39.  
  40.   plugins: [
  41.     commonjs({
  42.       ignoreGlobal: true,
  43.       namedExports: {
  44.         'node_modules/inferno-redux/index.js': ['Provider'],
  45.         'node_modules/aws-sdk/global.js': ['util'],
  46.       },
  47.     }),
  48.     globals(),
  49.     builtins(),
  50.     resolve({
  51.       preferBuiltins: true,
  52.     }),
  53.     sourcemaps(),
  54.     json(),
  55.   ],
  56.  
  57. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement