-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(build): Update dependencies and build pipeline #51
Changes from all commits
48acd36
ba5adef
0705144
1f41b07
5e17342
50adfbf
56aa2ff
c36af62
32d0eb2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,8 @@ const rollupNodeResolve = require('rollup-plugin-node-resolve'); | |
const rollupCommonjs = require('rollup-plugin-commonjs'); | ||
const rollupJson = require('rollup-plugin-json'); | ||
const rollupReplace = require('rollup-plugin-replace'); | ||
const rollupUglify = require('rollup-plugin-uglify'); | ||
const rollupTypescript = require('rollup-plugin-typescript'); | ||
const {uglify: rollupUglify} = require('rollup-plugin-uglify'); | ||
|
||
const FORMAT_ESM = 'esm'; | ||
const FORMAT_CJS = 'cjs'; | ||
|
@@ -109,6 +110,9 @@ const _genDist = ({minify = false} = {}) => | |
// convert JSON files to ES6 modules, so they can be included in Rollup bundle | ||
rollupJson(), | ||
|
||
// gives rollup ability to read typescript files | ||
rollupTypescript(), | ||
|
||
// Locate modules using the Node resolution algorithm, for using third party modules in node_modules | ||
rollupNodeResolve({ | ||
// use "module" field for ES6 module if possible | ||
|
@@ -186,13 +190,16 @@ gulp.task('build:dist:min', () => _genDist({minify: true})); | |
gulp.task('build:lib:umd', () => _genUmd()); | ||
gulp.task('build:lib:umd:min', () => _genUmd({minify: true})); | ||
|
||
gulp.task('build:lib', [ | ||
'build:lib:esm', | ||
'build:lib:cjs', | ||
'build:lib:umd', | ||
'build:lib:umd:min', | ||
]); | ||
gulp.task( | ||
'build:lib', | ||
gulp.series( | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh looks like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes I assumed we wanted to use series, but I am open to using parallel. |
||
'build:lib:esm', | ||
'build:lib:cjs', | ||
'build:lib:umd', | ||
'build:lib:umd:min' | ||
) | ||
); | ||
|
||
gulp.task('build', ['build:lib', 'build:dist', 'build:dist:min']); | ||
gulp.task('build', gulp.series('build:lib', 'build:dist', 'build:dist:min')); | ||
|
||
gulp.task('default', ['build']); | ||
gulp.task('default', gulp.series('build')); |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ module.exports = Object.assign({}, baseConfig, { | |
runner: 'jest-runner-eslint', | ||
displayName: 'lint', | ||
testMatch: ['<rootDir>/src/**/*.(ts|js)'], | ||
watchPlugins: ['jest-runner-eslint/watch-fix'], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is nice! There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah! It was painful not having that. Very nice to have it as a watch option. |
||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting! How was this working before????
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not really sure about that. It was in out package.json so maybe it was implied.