kopia lustrzana https://github.com/wagtail/wagtail
Remove polyfills only installed for IE11
rodzic
f16d29e788
commit
d2d4651853
|
@ -1,14 +0,0 @@
|
|||
/**
|
||||
* Polyfills for Wagtail's admin.
|
||||
*/
|
||||
|
||||
// IE11.
|
||||
import 'core-js/shim';
|
||||
// IE11, old iOS Safari.
|
||||
import 'whatwg-fetch';
|
||||
// IE11.
|
||||
import 'element-closest';
|
||||
// IE11
|
||||
import 'formdata-polyfill';
|
||||
// IE11
|
||||
import 'url-search-params-polyfill';
|
|
@ -3,7 +3,6 @@
|
|||
* Those variables usually come from the back-end via templates.
|
||||
* See /wagtailadmin/templates/wagtailadmin/admin_base.html.
|
||||
*/
|
||||
import 'element-closest';
|
||||
|
||||
global.wagtailConfig = {
|
||||
ADMIN_API: {
|
||||
|
|
|
@ -75,14 +75,6 @@ module.exports = function exports(env, argv) {
|
|||
import: [`./client/src/entrypoints/${appName}/${moduleName}.js`],
|
||||
filename: getOutputPath(appName, 'js', moduleName) + '.js',
|
||||
};
|
||||
|
||||
// Add polyfills to all bundles except userbar
|
||||
// polyfills.js imports from node_modules, which adds a dependency on vendor.js (produced by splitChunks)
|
||||
// Because userbar is supposed to run on peoples frontends, we code it using portable JS so we don't need
|
||||
// to pull in all the additional JS that the vendor bundle has (such as React).
|
||||
if (moduleName !== 'userbar') {
|
||||
entry[moduleName].import.push('./client/src/utils/polyfills.js');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -7,13 +7,10 @@
|
|||
"": {
|
||||
"version": "1.0.0",
|
||||
"dependencies": {
|
||||
"core-js": "^2.5.3",
|
||||
"draft-js": "^0.10.5",
|
||||
"draftail": "^1.4.1",
|
||||
"draftjs-filters": "^2.5.0",
|
||||
"element-closest": "^2.0.2",
|
||||
"focus-trap-react": "^8.4.2",
|
||||
"formdata-polyfill": "^3.0.20",
|
||||
"immer": "^9.0.6",
|
||||
"js-cookie": "^2.2.1",
|
||||
"postcss-calc": "^7.0.5",
|
||||
|
@ -26,9 +23,7 @@
|
|||
"redux-thunk": "^2.3.0",
|
||||
"reselect": "^4.0.0",
|
||||
"telepath-unpack": "^0.0.3",
|
||||
"url-search-params-polyfill": "^8.1.1",
|
||||
"uuid": "^8.3.2",
|
||||
"whatwg-fetch": "^2.0.3"
|
||||
"uuid": "^8.3.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.16.7",
|
||||
|
@ -13387,13 +13382,6 @@
|
|||
"url": "https://github.com/sponsors/sindresorhus"
|
||||
}
|
||||
},
|
||||
"node_modules/core-js": {
|
||||
"version": "2.6.12",
|
||||
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz",
|
||||
"integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==",
|
||||
"deprecated": "core-js@<3.4 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Please, upgrade your dependencies to the actual version of core-js.",
|
||||
"hasInstallScript": true
|
||||
},
|
||||
"node_modules/core-js-compat": {
|
||||
"version": "3.20.3",
|
||||
"resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.20.3.tgz",
|
||||
|
@ -14665,14 +14653,6 @@
|
|||
"integrity": "sha512-FNC+P5K1n6pF+M0zIK+gFCoXcJhhzDViL3DRIGy2Fv5PohuSES1JHR7T+GlwxSxlzx4yYbsuzCZvHxcBSRCIOw==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/element-closest": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/element-closest/-/element-closest-2.0.2.tgz",
|
||||
"integrity": "sha1-cqdAoQdFM4LijfnOXbtajfD5Zuw=",
|
||||
"engines": {
|
||||
"node": ">=4.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/element-resize-detector": {
|
||||
"version": "1.2.4",
|
||||
"resolved": "https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.2.4.tgz",
|
||||
|
@ -16876,11 +16856,6 @@
|
|||
"node": ">=0.4.x"
|
||||
}
|
||||
},
|
||||
"node_modules/formdata-polyfill": {
|
||||
"version": "3.0.20",
|
||||
"resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-3.0.20.tgz",
|
||||
"integrity": "sha512-TAaxIEwTBdoH1TWndtUH1T0/GisUHwmOKcV5hjkR/iTatHBJSOHb563FP86Lra5nXo3iNdhK7HPwMl5Ihg71pg=="
|
||||
},
|
||||
"node_modules/forwarded": {
|
||||
"version": "0.2.0",
|
||||
"resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz",
|
||||
|
@ -27922,11 +27897,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"node_modules/url-search-params-polyfill": {
|
||||
"version": "8.1.1",
|
||||
"resolved": "https://registry.npmjs.org/url-search-params-polyfill/-/url-search-params-polyfill-8.1.1.tgz",
|
||||
"integrity": "sha512-KmkCs6SjE6t4ihrfW9JelAPQIIIFbJweaaSLTh/4AO+c58JlDcb+GbdPt8yr5lRcFg4rPswRFRRhBGpWwh0K/Q=="
|
||||
},
|
||||
"node_modules/url/node_modules/punycode": {
|
||||
"version": "1.3.2",
|
||||
"resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz",
|
||||
|
@ -39549,11 +39519,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"core-js": {
|
||||
"version": "2.6.12",
|
||||
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz",
|
||||
"integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ=="
|
||||
},
|
||||
"core-js-compat": {
|
||||
"version": "3.20.3",
|
||||
"resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.20.3.tgz",
|
||||
|
@ -40578,11 +40543,6 @@
|
|||
"integrity": "sha512-FNC+P5K1n6pF+M0zIK+gFCoXcJhhzDViL3DRIGy2Fv5PohuSES1JHR7T+GlwxSxlzx4yYbsuzCZvHxcBSRCIOw==",
|
||||
"dev": true
|
||||
},
|
||||
"element-closest": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/element-closest/-/element-closest-2.0.2.tgz",
|
||||
"integrity": "sha1-cqdAoQdFM4LijfnOXbtajfD5Zuw="
|
||||
},
|
||||
"element-resize-detector": {
|
||||
"version": "1.2.4",
|
||||
"resolved": "https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.2.4.tgz",
|
||||
|
@ -42319,11 +42279,6 @@
|
|||
"integrity": "sha1-1hcBB+nv3E7TDJ3DkBbflCtctYs=",
|
||||
"dev": true
|
||||
},
|
||||
"formdata-polyfill": {
|
||||
"version": "3.0.20",
|
||||
"resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-3.0.20.tgz",
|
||||
"integrity": "sha512-TAaxIEwTBdoH1TWndtUH1T0/GisUHwmOKcV5hjkR/iTatHBJSOHb563FP86Lra5nXo3iNdhK7HPwMl5Ihg71pg=="
|
||||
},
|
||||
"forwarded": {
|
||||
"version": "0.2.0",
|
||||
"resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz",
|
||||
|
@ -50750,11 +50705,6 @@
|
|||
"schema-utils": "^3.0.0"
|
||||
}
|
||||
},
|
||||
"url-search-params-polyfill": {
|
||||
"version": "8.1.1",
|
||||
"resolved": "https://registry.npmjs.org/url-search-params-polyfill/-/url-search-params-polyfill-8.1.1.tgz",
|
||||
"integrity": "sha512-KmkCs6SjE6t4ihrfW9JelAPQIIIFbJweaaSLTh/4AO+c58JlDcb+GbdPt8yr5lRcFg4rPswRFRRhBGpWwh0K/Q=="
|
||||
},
|
||||
"use": {
|
||||
"version": "3.1.1",
|
||||
"resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz",
|
||||
|
|
|
@ -89,13 +89,10 @@
|
|||
"webpack-cli": "^4.9.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"core-js": "^2.5.3",
|
||||
"draft-js": "^0.10.5",
|
||||
"draftail": "^1.4.1",
|
||||
"draftjs-filters": "^2.5.0",
|
||||
"element-closest": "^2.0.2",
|
||||
"focus-trap-react": "^8.4.2",
|
||||
"formdata-polyfill": "^3.0.20",
|
||||
"immer": "^9.0.6",
|
||||
"js-cookie": "^2.2.1",
|
||||
"postcss-calc": "^7.0.5",
|
||||
|
@ -108,9 +105,7 @@
|
|||
"redux-thunk": "^2.3.0",
|
||||
"reselect": "^4.0.0",
|
||||
"telepath-unpack": "^0.0.3",
|
||||
"url-search-params-polyfill": "^8.1.1",
|
||||
"uuid": "^8.3.2",
|
||||
"whatwg-fetch": "^2.0.3"
|
||||
"uuid": "^8.3.2"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "webpack --config ./client/webpack.config.js --mode development --progress --watch",
|
||||
|
|
Ładowanie…
Reference in New Issue