Skip to content

Instantly share code, notes, and snippets.

@giacomoalonzi
Created October 5, 2018 14:42
Show Gist options
  • Save giacomoalonzi/389248635b0d16fb20f2eeae86d2a89d to your computer and use it in GitHub Desktop.
Save giacomoalonzi/389248635b0d16fb20f2eeae86d2a89d to your computer and use it in GitHub Desktop.
configuration for vue lib export
import vue from 'rollup-plugin-vue'
import buble from 'rollup-plugin-buble'
import resolve from 'rollup-plugin-node-resolve'
import postcss from 'rollup-plugin-postcss'
export default {
input: 'src/components/index.js',
output: {
name: 'serpe',
file: './package/serpe.bundle.js',
format: 'umd',
global: {
'vue': 'vue'
}
},
external: [
'lodash',
'vue',
'ramda'
],
plugins: [
vue({
css: true,
compileTemplate: true
}),
postcss({
extract: true,
minimize: true
}),
buble(),
resolve({
customResolveOptions: {
moduleDirectory: '../../node_modules'
}
})
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment