Use babel-eslint for parsing (#2073)

Eslint's default parser cannot handle some newer es6+ syntax (e.g.
dynamic import() function). Babel-eslint uses babel for parsing instead
which can handle the newer syntax

GitOrigin-RevId: 0a5666ac3bdc3c0885842dcdbc6f6d3b4dbf2d4b
This commit is contained in:
Alasdair Smith 2019-08-19 16:17:13 +01:00 committed by sharelatex
parent 9a8a182c1b
commit c5da705fa0
3 changed files with 19 additions and 2 deletions

View file

@ -14,6 +14,7 @@
"chai-expect",
"chai-friendly"
],
"parser": "babel-eslint",
"env": {
"browser": true,
"mocha": true

View file

@ -1,5 +1,5 @@
{
"name": "web-sharelatex",
"name": "web-overleaf",
"version": "0.1.4",
"lockfileVersion": 1,
"requires": true,
@ -2807,6 +2807,20 @@
"js-tokens": "^3.0.2"
}
},
"babel-eslint": {
"version": "10.0.2",
"resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.0.2.tgz",
"integrity": "sha512-UdsurWPtgiPgpJ06ryUnuaSXC2s0WoSZnQmEpbAH65XZSdwowgN5MvyP7e88nW07FYXv72erVtpBkxyDVKhH1Q==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.0.0",
"@babel/parser": "^7.0.0",
"@babel/traverse": "^7.0.0",
"@babel/types": "^7.0.0",
"eslint-scope": "3.7.1",
"eslint-visitor-keys": "^1.0.0"
}
},
"babel-loader": {
"version": "8.0.6",
"resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-8.0.6.tgz",
@ -19227,7 +19241,8 @@
"timekeeper": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/timekeeper/-/timekeeper-2.2.0.tgz",
"integrity": "sha512-W3AmPTJWZkRwu+iSNxPIsLZ2ByADsOLbbLxe46UJyWj3mlYLlwucKiq+/dPm0l9wTzqoF3/2PH0AGFCebjq23A=="
"integrity": "sha512-W3AmPTJWZkRwu+iSNxPIsLZ2ByADsOLbbLxe46UJyWj3mlYLlwucKiq+/dPm0l9wTzqoF3/2PH0AGFCebjq23A==",
"dev": true
},
"timers-browserify": {
"version": "2.0.10",

View file

@ -115,6 +115,7 @@
"devDependencies": {
"acorn": "^6.1.0",
"acorn-walk": "^6.1.1",
"babel-eslint": "^10.0.2",
"babel-loader": "^8.0.6",
"babel-plugin-angularjs-annotate": "^0.10.0",
"chai": "3.5.0",