1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-29 07:16:36 +01:00
Commit Graph

9 Commits

Author SHA1 Message Date
Mark Stacey
2a7278eb7e
Remove Babel transformations for older browser versions (#6812)
The Babel config had previously supported all browsers with greater than
0.25% global usage (according to `browserlist`). This resulted in
`babel-preset-env` including plugins sufficient to support the following
minimum browser versions:

```
{
  "chrome": "49",
  "android": "4.4",
  "edge": "16",
  "firefox": "52",
  "ios": "9.3",
  "safari": "11"
}
```

Instead, the babel config now explicitly supports chrome >= 58 and
firefox >= 53. Chrome and Firefox are the only browsers we currently
publish to, and these were the minimum versions with no additional Babel
transformations.

The minimum browser versions we support should be re-evaluated later,
when we have added tests and documentation.

The plugin 'transform-async-to-generator' has also been removed. It was
used to translate async/await, but our browser targets all support
async/await.

Removing some of these transformations exposed bugs in `uglify-es` that
only presented themselves in the production build. `gulp-uglify-es` has
been updated to a version that uses `terser` instead of `uglify-es`,
which has resolved these issues.

Relates to #6805
2019-07-18 18:17:20 -03:00
Mark Stacey
7f7517b9e6
Remove unused Babel transformations (#6811)
The `stage-0` Babel preset has been replaced with the specific Babel
plugins that we depend upon. We don't use most of `stage-0`, so this
allowed us to remove many unnecessary transformations. We had to remove
this preset soon anyway, because all of the stage presets are
deprecated in Babel 7.

The `stage-0` preset consisted of these plugins:
```
"transform-do-expressions"
"transform-function-bind"
"transform-class-constructor-call"
"transform-export-extensions"
"transform-class-properties"
"transform-decorators"
"syntax-dynamic-import"
"syntax-trailing-function-commas"
"transform-async-generator-functions"
"transform-async-to-generator"
"transform-exponentiation-operator"
"transform-object-rest-spread"
```

Of that list, only 'transform-class-properties', 'transform-object-
rest-spread', and 'transform-async-to-generator' were being used.
2019-07-05 16:08:11 -03:00
kumavis
e072a3d993 build - babel - move config to babelrc (#6284) 2019-03-12 13:25:28 -02:30
Antoine Nauleau
3854650546 Minimum Browsers Supported (#4873)
* Minimum supported browsers and version standard: add browsers and targets to .babelrc and package.json

* Regenerate package.json, fix issue with comma in merge

* Resolve merge conflicts

* Regenerate package-lock.json

* Revert to previous package-lock.json
2018-08-22 20:20:24 -02:30
Thomas
138858647e Merge branch 'develop' into network-remove-provider-engine 2018-07-25 22:38:44 -07:00
Antoine Nauleau
653e42cf79 Update Babel to Current Standard "babel-preset-env" (#4812)
* Update .babelrc and package.json to babel-preset-env standard

* Install babel-preset-env babel-stage-0

* Regenerate package-lock.json by running npm install --package-lock-only && npm audit fix

* Resolve PR #4812 merge conflicts

* Merge #4847 Solves previous cache issues with cirlce-ci
2018-07-24 15:21:32 -02:30
Jacky Chan
0264ecaad7 Adding CreatePasswordScreen 2017-10-20 21:51:37 -07:00
Dan Finlay
9bae32e78b Add functional but ugly and hard-coded token list 2017-04-20 19:10:22 -07:00
Dan Finlay
da31f4daed Added basic es6 mocha test suite 2016-03-24 17:51:46 -07:00