-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BREAKING CHANGE: an es5-specific build is included in the dist closes #83
- Loading branch information
1 parent
d70483b
commit 53508cc
Showing
5 changed files
with
183 additions
and
89 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
import babel from 'rollup-plugin-babel'; | ||
import localResolve from 'rollup-plugin-node-resolve'; | ||
import path from 'path'; | ||
|
||
export default { | ||
input: 'src/index.ts', | ||
output: [ | ||
{ | ||
file: 'dist/es5.js', | ||
format: 'cjs', | ||
exports: 'named', | ||
}, | ||
], | ||
plugins: [ | ||
localResolve({ | ||
extensions: [ '.js', '.ts' ], | ||
}), | ||
babel({ | ||
exclude: 'node_modules/**', | ||
extensions: [ '.js', '.ts' ], | ||
presets: [ | ||
[ | ||
'@babel/preset-env', | ||
{ | ||
targets: { | ||
browsers: [ | ||
'last 2 versions', | ||
'safari >= 7', | ||
], | ||
}, | ||
modules: false, | ||
useBuiltIns: false, | ||
loose: true, | ||
}, | ||
], | ||
], | ||
plugins: [ | ||
[ | ||
path.resolve('./babel-plugin.js'), | ||
{ publicPath: true }, | ||
], | ||
], | ||
}), | ||
], | ||
}; |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
import plugin from './rollup.config.plugin'; | ||
import src from './rollup.config.src'; | ||
import es5 from './rollup.config.es5'; | ||
|
||
export default [ | ||
plugin, | ||
src, | ||
es5, | ||
]; |
Oops, something went wrong.