Skip to content

Commit

Permalink
chore #222 - Optimize build (#223)
Browse files Browse the repository at this point in the history
Closes #222

Co-authored-by: github-actions <[email protected]>
  • Loading branch information
nancy-dassana and github-actions authored Feb 19, 2021
1 parent f5ba46c commit f9361c9
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 4 deletions.
59 changes: 58 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dassana-io/web-components",
"version": "0.9.0",
"version": "0.9.1",
"publishConfig": {
"registry": "https://npm.pkg.github.com/dassana-io"
},
Expand Down Expand Up @@ -106,6 +106,7 @@
"react-test-renderer": "^16.14.0",
"rollup": "^2.32.1",
"rollup-plugin-styles": "^3.11.0",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.28.0"
},
"peerDependencies": {
Expand Down
16 changes: 14 additions & 2 deletions rollup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import pkg from './package.json'
import resolve from '@rollup/plugin-node-resolve'
import styles from 'rollup-plugin-styles'
import svgr from '@svgr/rollup'
import { terser } from 'rollup-plugin-terser'
import typescript from 'rollup-plugin-typescript2'

const assetFileNames = '[name]-[hash][extname]'
Expand All @@ -29,14 +30,24 @@ const rootImport = options => ({

export default {
external: [
'antd',
'@ant-design/icons',
'@dassana-io/web-utils',
'@fortawesome/fontawesome-svg-core',
'@fortawesome/free-solid-svg-icons',
'@fortawesome/react-fontawesome',
'antd',
'bytes',
'classnames',
'color',
'framer-motion',
'fuse.js',
'lodash',
'moment',
'react',
'react-dom',
'react-hook-form',
'react-jss',
'typescript',
'uuid'
],
input: 'src/components/index.ts',
Expand Down Expand Up @@ -64,6 +75,7 @@ export default {
typescript({
tsconfig: 'tsconfig.rollup.json',
useTsconfigDeclarationDir: true
})
}),
terser()
]
}

0 comments on commit f9361c9

Please sign in to comment.