Last active
October 1, 2021 02:26
-
-
Save lmartim/2d2927b2ab57743b724cc45f10798b8e to your computer and use it in GitHub Desktop.
The rollup config for building the component library.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import vue from 'rollup-plugin-vue' | |
import { terser } from 'rollup-plugin-terser' | |
import postcss from 'rollup-plugin-postcss' | |
module.exports = [ | |
{ | |
input: 'src/index.js', | |
output: [ | |
{ | |
sourcemap: true, | |
file: 'dist/index.js', | |
format: 'es' | |
} | |
], | |
inlineDynamicImports: true, | |
plugins: [ | |
vue({ | |
preprocessStyles: true, | |
preprocessOptions: { | |
scss: { | |
additionalData: ` | |
@import 'dist/tokens/_variables.scss'; | |
@import 'dist/styles/styles.scss'; | |
` | |
} | |
} | |
}), | |
terser(), | |
postcss() | |
] | |
} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment