Skip to content

Commit

Permalink
Add UDM support
Browse files Browse the repository at this point in the history
  • Loading branch information
99ff00 committed Sep 30, 2019
1 parent 8352a74 commit a6eff3a
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,24 @@ const sourcemap = !production ? 'inline' : false;

export default {
input: 'src/index.js',
external: ['react', 'react-dom', 'prop-types'],
output: [
{
file: pkg.main,
format: 'cjs',
format: 'umd',
name: 'Charty',
globals: {
'react': 'React',
'react-dom': 'ReactDOM',
'prop-types': 'PropTypes'
},
sourcemap
},
{
file: pkg.module,
format: 'es',
format: 'esm',
sourcemap
}
},
],
plugins: [
external(),
Expand Down

0 comments on commit a6eff3a

Please sign in to comment.