Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit d4a641e

Browse files
marclavalIgorMinar
authored andcommitted
docs(browser-support): document browser support and polyfills (#2244)
1 parent 2c9e78c commit d4a641e

File tree

4 files changed

+198
-0
lines changed

4 files changed

+198
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
!= partial("../../../_includes/_ts-temp")
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
!= partial("../../../_includes/_ts-temp")

public/docs/ts/latest/guide/_data.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,11 @@
8686
"intro": "Attribute directives attach behavior to elements."
8787
},
8888

89+
"browser-support": {
90+
"title": "Browser support",
91+
"intro": "Browser support and polyfills guide."
92+
},
93+
8994
"component-styles": {
9095
"title": "Component Styles",
9196
"intro": "Learn how to apply CSS styles to components."
Lines changed: 191 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,191 @@
1+
:marked
2+
# Browser support #
3+
Angular supports most recent browsers. This includes the following specific versions:
4+
5+
table
6+
tr
7+
th Chrome
8+
th Firefox
9+
th Edge
10+
th IE
11+
th Safari
12+
th iOS
13+
th Android
14+
th IE mobile
15+
tr
16+
td latest
17+
td latest
18+
td 14
19+
td 11
20+
td 9
21+
td 9
22+
td Marshmallow (6.0)
23+
td 11
24+
tr
25+
td
26+
td
27+
td 13
28+
td 10
29+
td 8
30+
td 8
31+
td Lollipop<br>(5.0, 5.1)
32+
td
33+
tr
34+
td
35+
td
36+
td
37+
td 9
38+
td 7
39+
td 7
40+
td KitKat<br>(4.4)
41+
td
42+
tr
43+
td
44+
td
45+
td
46+
td
47+
td
48+
td
49+
td Jelly Bean<br>(4.1, 4.2, 4.3)
50+
td
51+
52+
53+
:marked
54+
To ensure this compatibility, the unit tests of the framework are run on all of them for every pull request.
55+
This is done as part of the continuous integration setup of the project, using [SauceLabs](https://saucelabs.com/) and [Browserstack](https://www.browserstack.com).
56+
57+
# Polyfills #
58+
Angular is built on the latest standards of the web platform.
59+
Targeting such a wide range of browsers can be challenging as they may not support all the features of modern browsers.
60+
61+
62+
To fill the gaps, the best solution is to use polyfills which "upgrade" old browsers by adding missing features.
63+
For each browser, some polyfill may be required to run any application, and some may be needed only when some features are used.
64+
65+
.alert.is-helpful
66+
span As a developer, depending on the browsers you target and on the features you use, you'll need to load a set of polyfills.
67+
span The tables below will help you making the right choices.
68+
69+
.alert.is-important
70+
span The polyfills documented here are the ones which were identified to run full Angular application.
71+
span Others may be needed if you decide to use extra features which are not supported everywhere.
72+
span On top of that, they will not magically transform an old and slow browser into a modern and fast one.
73+
74+
:marked
75+
## Mandatory polyfills ##
76+
For each supported browser, these are the polyfills which are required to run an application:
77+
78+
table
79+
tr
80+
th Browsers (desktop & mobile)
81+
th Polyfills required
82+
tr
83+
td Chrome, Firefox, Edge, Safari 9+
84+
td None
85+
tr
86+
td Safari 7 & 8, IE10 & 11, Android 4.1+
87+
td ES6
88+
tr
89+
td IE9
90+
td ES6<br>classList
91+
92+
93+
:marked
94+
## Optional browser features to polyfill ##
95+
In addition to the mandatory polyfills, some features of Angular may require some extra polyfills.
96+
97+
For example, the animations use the standard web animation API, which is only available in Chrome and Firefox today.
98+
In order to use this feature in other browsers, the correct polyfill is needed.
99+
100+
Here are the features which may require additional polyfills:
101+
102+
table
103+
tr
104+
th Feature
105+
th Polyfill
106+
th Browsers (desktop & mobile)
107+
tr
108+
td
109+
a(href="./animations.html") Animations
110+
td Web Animations
111+
td All but Chrome and Firefox<br>Not supported in IE9
112+
tr
113+
td
114+
a(href="../api/common/index/DatePipe-class.html") Date
115+
span ,
116+
a(href="../api/common/index/CurrencyPipe-class.html") currency
117+
span ,
118+
a(href="../api/common/index/DecimalPipe-class.html") decimal
119+
span and
120+
a(href="../api/common/index/PercentPipe-class.html") percent
121+
span pipes
122+
td Intl API
123+
td All but Chrome, Firefox, Edge and IE11
124+
tr
125+
td
126+
a(href="../api/common/index/NgClass-directive.html") NgClass
127+
span on SVG elements
128+
td classList
129+
td IE10, IE11
130+
tr
131+
td
132+
a(href="./server-communication.html") Http
133+
span when sending and receiving binary data
134+
td Typed Arrays<br>Blob<br>FormData
135+
td IE 9
136+
137+
:marked
138+
## Suggested polyfills ##
139+
Below are the polyfills which are used to test the framework itself. They are a good starting point for an application.
140+
141+
table
142+
tr
143+
th Polyfill
144+
th Library
145+
th Licence
146+
th Size*
147+
tr
148+
td ES6
149+
td
150+
a(href="https://github.com/zloirock/core-js") https://github.com/zloirock/core-js
151+
td MIT
152+
td 27.4KB
153+
tr
154+
td classList
155+
td
156+
a(href="https://github.com/eligrey/classList.js") https://github.com/eligrey/classList.js
157+
td Public domain
158+
td 1KB
159+
tr
160+
td Intl
161+
td
162+
a(href="https://github.com/andyearnshaw/Intl.js ") https://github.com/andyearnshaw/Intl.js
163+
td MIT / Unicode licence
164+
td 13.5KB
165+
tr
166+
td Web Animations
167+
td
168+
a(href="https://github.com/web-animations/web-animations-js") https://github.com/web-animations/web-animations-js
169+
td Apache
170+
td 14.8KB
171+
tr
172+
td Typed Arrays
173+
td
174+
a(href="https://github.com/inexorabletash/polyfill/blob/master/typedarray.js") https://github.com/inexorabletash/polyfill/blob/master/typedarray.js
175+
td MIT
176+
td 4KB
177+
tr
178+
td Blob
179+
td
180+
a(href="https://github.com/eligrey/Blob.js") https://github.com/eligrey/Blob.js
181+
td MIT
182+
td 1.3KB
183+
tr
184+
td FormData
185+
td
186+
a(href="https://github.com/francois2metz/html5-formdata") https://github.com/francois2metz/html5-formdata
187+
td MIT
188+
td 0.4KB
189+
190+
:marked
191+
*Figures are for minified and gzipped code, computed with [http://closure-compiler.appspot.com/home](http://closure-compiler.appspot.com/home)

0 commit comments

Comments
 (0)