Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Angular 6 app is not working in safari browser

Angular app is working fine in IE and chrome but in safari it is not working even not showing any error and tried with polyfill

and here polyfill.ts

/** IE9, IE10 and IE11 requires all of the following polyfills. **/
import 'core-js/es6/symbol';
 import 'core-js/es6/object';
 import 'core-js/es6/function';
 import 'core-js/es6/parse-int';
 import 'core-js/es6/parse-float';
 import 'core-js/es6/number';
 import 'core-js/es6/math';
 import 'core-js/es6/string';
 import 'core-js/es6/date';
 import 'core-js/es6/array';
 import 'core-js/es6/regexp';
 import 'core-js/es6/map';
  import 'core-js/es6/weak-map';
 import 'core-js/es6/set';
import 'core-js/client/shim';
import 'intl';
import 'intl/locale-data/jsonp/en';

/** IE10 and IE11 requires the following for NgClass support on SVG elements */
 import 'classlist.js';  // Run `npm install --save classlist.js`.

/** IE10 and IE11 requires the following for the Reflect API. */
 import 'core-js/es6/reflect';


/** Evergreen browsers require these. **/
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
import 'core-js/es7/reflect';

   import 'web-animations-js';  // Run `npm install --save web-animations-js`.


import 'zone.js/dist/zone';  // Included with Angular CLI.

and in package.json all are with 6.x version

like image 547
Narendar Avatar asked Mar 19 '19 14:03

Narendar


People also ask

Does Angular work with mobile browsers?

AngularJS is 100% JavaScript, 100% client-side and compatible with both desktop and mobile browsers.

Does Angular need polyfills?

Angular is built on the latest standards of the web platform. Targeting such a wide range of browsers is challenging because they do not support all features of modern browsers. You compensate by loading polyfill scripts ("polyfills") for the browsers that you must support.


1 Answers

Angular 6 support Safari version >= 10. On windows system latest version of safari is 5 and on Mac it is 12 as of now(1st Aug 2019). If you are verifying on windows safari, it will not work. You need to check it on Mac machine.

You can check safari release history here

like image 115
rishikesh tadaka Avatar answered Sep 22 '22 04:09

rishikesh tadaka