Skip to content

Commit

Permalink
Babel plugins: remove outdated proposals (#1074)
Browse files Browse the repository at this point in the history
* Babel plugins: remove outdated proposals

- Also updates the browserlist to be more succint.
- Also migrates from rollup-plugin-babel --> @rollup/plugin-babel

* Update rollup.plugins.js

* revert browserlist jic
  • Loading branch information
samouri authored Jul 13, 2021
1 parent c1d49b1 commit d2baf04
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions config/rollup.plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

import babel from 'rollup-plugin-babel';
import babel from '@rollup/plugin-babel';
import MagicString from 'magic-string';
import fs from 'fs';
import * as path from 'path';
Expand All @@ -32,6 +32,7 @@ export function babelPlugin({ transpileToES5, allowConsole = false, allowPostMes
const exclude = allowConsole ? ['error', 'warn', 'trace', 'info', 'log', 'time', 'timeEnd'] : [];

return babel({
babelHelpers: 'bundled',
exclude: 'node_modules/**',
presets: [
[
Expand All @@ -45,8 +46,6 @@ export function babelPlugin({ transpileToES5, allowConsole = false, allowPostMes
],
],
plugins: [
['@babel/plugin-proposal-object-rest-spread'],
['@babel/proposal-class-properties'],
[
'babel-plugin-minify-replace',
{
Expand Down
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,8 @@
"@ampproject/rollup-plugin-closure-compiler": "0.26.0",
"@babel/cli": "7.14.5",
"@babel/core": "7.14.6",
"@babel/plugin-proposal-class-properties": "7.14.5",
"@babel/plugin-proposal-object-rest-spread": "7.14.7",
"@babel/preset-env": "7.14.7",
"@rollup/plugin-babel": "5.3.0",
"@rollup/plugin-replace": "2.4.2",
"@types/node": "14.17.3",
"@types/sinon": "10.0.2",
Expand Down

0 comments on commit d2baf04

Please sign in to comment.