You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
683 B
27 lines
683 B
const commonjs = require('rollup-plugin-commonjs');
|
|
const postcss = require('rollup-plugin-postcss');
|
|
const resolve = require('rollup-plugin-node-resolve');
|
|
const replace = require('@rollup/plugin-replace');
|
|
const typescript = require('@rollup/plugin-typescript');
|
|
|
|
const production = process.env.NODE_ENV === 'production';
|
|
|
|
module.exports = {
|
|
input: 'src/index.ts',
|
|
output: {
|
|
file: 'dist/index.js',
|
|
format: 'umd',
|
|
name: 'EmojiButton'
|
|
},
|
|
plugins: [
|
|
replace({
|
|
'process.env.NODE_ENV': JSON.stringify(production ? 'production' : 'development')
|
|
}),
|
|
postcss({
|
|
extensions: ['.css']
|
|
}),
|
|
typescript(),
|
|
resolve(),
|
|
commonjs()
|
|
]
|
|
};
|
|
|