mirror of
https://github.com/prymitive/karma
synced 2026-05-19 04:26:41 +00:00
Merge pull request #646 from prymitive/polyfill
refactor(ui): use react-app-polyfill instead of @babel/polyfill
This commit is contained in:
@@ -48,14 +48,14 @@ func TestCustomizationAssets(t *testing.T) {
|
||||
customJS: "ui/.env",
|
||||
path: "/custom.js",
|
||||
code: 200,
|
||||
body: "NODE_PATH=src\nPUBLIC_URL=.\n",
|
||||
body: "PUBLIC_URL=.\n",
|
||||
mime: "text/plain; charset=utf-8",
|
||||
},
|
||||
{
|
||||
customCSS: "ui/.env",
|
||||
path: "/custom.css",
|
||||
code: 200,
|
||||
body: "NODE_PATH=src\nPUBLIC_URL=.\n",
|
||||
body: "PUBLIC_URL=.\n",
|
||||
mime: "text/plain; charset=utf-8",
|
||||
},
|
||||
}
|
||||
|
||||
6
ui/jsconfig.json
Normal file
6
ui/jsconfig.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"baseUrl": "src"
|
||||
},
|
||||
"include": ["src"]
|
||||
}
|
||||
@@ -5,7 +5,6 @@
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@attently/riek": "2.0.1",
|
||||
"@babel/polyfill": "7.4.3",
|
||||
"@fortawesome/fontawesome-svg-core": "1.2.17",
|
||||
"@fortawesome/free-regular-svg-icons": "5.8.1",
|
||||
"@fortawesome/free-solid-svg-icons": "5.8.1",
|
||||
@@ -31,6 +30,7 @@
|
||||
"prop-types": "15.7.2",
|
||||
"qs": "6.7.0",
|
||||
"react": "16.8.6",
|
||||
"react-app-polyfill": "1.0.0",
|
||||
"react-autosuggest": "9.4.3",
|
||||
"react-datepicker": "2.4.0",
|
||||
"react-dom": "16.8.6",
|
||||
@@ -50,8 +50,7 @@
|
||||
"react-tippy": "1.2.3",
|
||||
"react-transition-group": "4.0.0",
|
||||
"react-truncate": "2.4.0",
|
||||
"semver": "6.0.0",
|
||||
"whatwg-fetch": "3.0.0"
|
||||
"semver": "6.0.0"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "NODE_ENV=dev REACT_APP_BACKEND_URI=http://localhost:8080 react-scripts start",
|
||||
@@ -73,13 +72,12 @@
|
||||
">= 1%",
|
||||
"last 1 major version",
|
||||
"not dead",
|
||||
"Chrome >= 45",
|
||||
"Chrome >= 49",
|
||||
"Firefox >= 38",
|
||||
"Edge >= 12",
|
||||
"Explorer >= 10",
|
||||
"iOS >= 9",
|
||||
"Safari >= 9",
|
||||
"Safari >= 10",
|
||||
"Android >= 4.4",
|
||||
"Opera >= 30"
|
||||
"Opera >= 36"
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
// MUST be first thing we import
|
||||
// https://babeljs.io/docs/en/babel-polyfill#usage-in-node-browserify-webpack
|
||||
import "@babel/polyfill";
|
||||
|
||||
// fetch() polyfill for IE and some mobile browsers
|
||||
import "whatwg-fetch";
|
||||
// https://github.com/facebook/create-react-app/blob/master/packages/react-app-polyfill/README.md
|
||||
import "react-app-polyfill/stable";
|
||||
|
||||
import React from "react";
|
||||
import ReactDOM from "react-dom";
|
||||
|
||||
12
ui/yarn.lock
12
ui/yarn.lock
@@ -677,14 +677,6 @@
|
||||
"@babel/helper-regex" "^7.4.3"
|
||||
regexpu-core "^4.5.4"
|
||||
|
||||
"@babel/polyfill@7.4.3":
|
||||
version "7.4.3"
|
||||
resolved "https://registry.yarnpkg.com/@babel/polyfill/-/polyfill-7.4.3.tgz#332dc6f57b718017c3a8b37b4eea8aa6eeac1187"
|
||||
integrity sha512-rkv8WIvJshA5Ev8iNMGgz5WZkRtgtiPexiT7w5qevGTuT7ZBfM3de9ox1y9JR5/OXb/sWGBbWlHNa7vQKqku3Q==
|
||||
dependencies:
|
||||
core-js "^2.6.5"
|
||||
regenerator-runtime "^0.13.2"
|
||||
|
||||
"@babel/preset-env@7.4.3", "@babel/preset-env@^7.1.6":
|
||||
version "7.4.3"
|
||||
resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.4.3.tgz#e71e16e123dc0fbf65a52cbcbcefd072fbd02880"
|
||||
@@ -3108,7 +3100,7 @@ core-js@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/core-js/-/core-js-1.2.7.tgz#652294c14651db28fa93bd2d5ff2983a4f08c636"
|
||||
integrity sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY=
|
||||
|
||||
core-js@^2.4.0, core-js@^2.5.0, core-js@^2.6.5:
|
||||
core-js@^2.4.0, core-js@^2.5.0:
|
||||
version "2.6.5"
|
||||
resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.5.tgz#44bc8d249e7fb2ff5d00e0341a7ffb94fbf67895"
|
||||
integrity sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A==
|
||||
@@ -9161,7 +9153,7 @@ rc@^1.2.7, rc@~1.2.7:
|
||||
minimist "^1.2.0"
|
||||
strip-json-comments "~2.0.1"
|
||||
|
||||
react-app-polyfill@^1.0.0:
|
||||
react-app-polyfill@1.0.0, react-app-polyfill@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/react-app-polyfill/-/react-app-polyfill-1.0.0.tgz#735c725c1d4261b710cb200c498789c8b80e0f74"
|
||||
integrity sha512-fbZxEZdfx+rVENMvGTFjUcDDOZGKHaiavA8Y+FwM2I/o8gJT6pCYZk19XfeOntVzGZH2F1qqH7SLjXMhUM+YJw==
|
||||
|
||||
Reference in New Issue
Block a user