Commit c2752f46 authored by 神楽坂玲奈's avatar 神楽坂玲奈

polyfill

parent 4abec5fd
#!/bin/bash
sed -i '' 's/,this._isFinished=!0//' node_modules/web-animations-js/web-animations.min.js
sed -i '' "s/ class:/ 'class':/g" node_modules/@angular/material/@angular/material.js
sed -i '' "s/ extends:/ 'extends':/" node_modules/intl/lib/core.js
{
"name": "mycard-mobile",
"version": "1.0.1",
"version": "1.0.4",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
......@@ -959,6 +959,11 @@
"chalk": "1.1.3"
}
},
"classlist.js": {
"version": "1.1.20150312",
"resolved": "https://registry.npmjs.org/classlist.js/-/classlist.js-1.1.20150312.tgz",
"integrity": "sha1-HXCEL3Ai8I2awIbOaeWyUPLFd4k="
},
"clean-css": {
"version": "4.1.7",
"resolved": "https://registry.npmjs.org/clean-css/-/clean-css-4.1.7.tgz",
......@@ -3841,6 +3846,11 @@
"integrity": "sha1-y8NcYu7uc/Gat7EKgBURQBr8D5A=",
"dev": true
},
"intl": {
"version": "1.2.5",
"resolved": "https://registry.npmjs.org/intl/-/intl-1.2.5.tgz",
"integrity": "sha1-giRKIZDE5Bn4Nx9ao02qNCDiq94="
},
"invariant": {
"version": "2.2.2",
"resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.2.tgz",
......@@ -5882,6 +5892,21 @@
"integrity": "sha1-DPf4T5Rj/wrlHExLFC2VvjdyTZw=",
"dev": true
},
"raf": {
"version": "3.3.2",
"resolved": "https://registry.npmjs.org/raf/-/raf-3.3.2.tgz",
"integrity": "sha1-DBO+C1tJtG921maSSNUnzysC/ic=",
"requires": {
"performance-now": "2.1.0"
},
"dependencies": {
"performance-now": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz",
"integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
}
}
},
"randomatic": {
"version": "1.1.7",
"resolved": "https://registry.npmjs.org/randomatic/-/randomatic-1.1.7.tgz",
......@@ -7363,6 +7388,11 @@
"minimalistic-assert": "1.0.0"
}
},
"web-animations-js": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/web-animations-js/-/web-animations-js-2.3.1.tgz",
"integrity": "sha1-Om2bwVGWN3qQ+OKAP6UmIWWwRRA="
},
"webpack": {
"version": "2.4.1",
"resolved": "https://registry.npmjs.org/webpack/-/webpack-2.4.1.tgz",
......
......@@ -6,7 +6,11 @@
"ng": "ng",
"start": "ng serve --base-href /mobile/index.html --deploy-url /mobile --locale zh-CN --output-path mobile --open",
"build": "ng build --base-href /mobile/index.html --locale zh-CN --aot --prod",
"lint": "ng lint"
"postinstall": "./fuck.sh",
"build:dev": "ng build --base-href /mobile2/index.html --locale zh-CN --aot",
"lint": "ng lint",
"publish": "npm run build && ./ossutil cp -rf dist oss://mycard/mobile",
"publish:dev": "npm run build:2 && ./ossutil cp -rf dist oss://mycard/mobile2"
},
"private": true,
"dependencies": {
......@@ -21,13 +25,17 @@
"@angular/platform-browser": "^4.0.0",
"@angular/platform-browser-dynamic": "^4.0.0",
"@angular/router": "^4.0.0",
"classlist.js": "^1.1.20150312",
"core-js": "^2.4.1",
"font-awesome": "^4.7.0",
"hammerjs": "^2.0.8",
"intl": "^1.2.5",
"lodash": "^4.17.4",
"material-design-icons": "^3.0.1",
"raf": "^3.3.2",
"rxjs": "^5.1.0",
"url-polyfill": "^1.0.6",
"web-animations-js": "^2.3.1",
"zone.js": "^0.8.4"
},
"devDependencies": {
......
......@@ -49,20 +49,10 @@
</div>
</app-root>
<script>
window.onerror = function (msg, url, lineNo, columnNo, error) {
if (msg.toLowerCase().indexOf('script error') > -1) {
alert('Script Error: See Browser Console for Detail');
} else {
alert([
'Message: ' + msg,
'URL: ' + url,
'Line: ' + lineNo,
'Column: ' + columnNo,
'Error object: ' + JSON.stringify(error)
].join('\n'));
}
return false;
};
// window.onerror = function (msg, url, lineNo, columnNo, error) {
// alert(msg);
// return false;
// };
</script>
</body>
</html>
......@@ -20,7 +20,7 @@
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
// import 'core-js/es6/symbol';
import 'core-js/es6/object';
// import 'core-js/es6/object';
// import 'core-js/es6/function';
// import 'core-js/es6/parse-int';
// import 'core-js/es6/parse-float';
......@@ -28,7 +28,7 @@ import 'core-js/es6/object';
// import 'core-js/es6/math';
// import 'core-js/es6/string';
// import 'core-js/es6/date';
import 'core-js/es6/array';
// import 'core-js/es6/array';
// import 'core-js/es6/regexp';
// import 'core-js/es6/map';
// import 'core-js/es6/weak-map';
......@@ -38,15 +38,17 @@ import 'core-js/es6/array';
// import 'classlist.js'; // Run `npm install --save classlist.js`.
/** Evergreen browsers require these. **/
import 'core-js/es6/reflect';
import 'core-js/es7/reflect';
// import 'core-js/es6/reflect';
// import 'core-js/es7/reflect';
import 'core-js/shim';
/**
* Required to support Web Animations `@angular/animation`.
* Needed for: All but Chrome, Firefox and Opera. http://caniuse.com/#feat=web-animation
**/
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
import 'raf/polyfill'
import 'web-animations-js'; // Run `npm install --save web-animations-js`.
......@@ -65,10 +67,10 @@ import 'zone.js/dist/zone'; // Included with Angular CLI.
* Date, currency, decimal and percent pipes.
* Needed for: All but Chrome, Firefox, Edge, IE11 and Safari 10
*/
// import 'intl'; // Run `npm install --save intl`.
import 'intl'; // Run `npm install --save intl`.
/**
* Need to import at least one locale-data with intl.
*/
// import 'intl/locale-data/jsonp/en';
import 'intl/locale-data/jsonp/zh-Hans-CN';
import 'url-polyfill';
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment