forked from GoogleChrome/samples
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·30 lines (27 loc) · 961 Bytes
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
---
feature_name: Classes (ES6)
chrome_version: 42
feature_id: 4633745457938432
---
<h3>Background</h3>
<p>
ES6 Classes formalize the common JavaScript pattern of simulating class-like inheritance hierarchies
using functions and prototypes. They are effectively simple sugaring over prototype-based OO, offering
a convenient declarative form for class patterns which encourage interoperability.
</p>
<p>
Classes (as shipped in Chrome) support prototype-based inheritance, constructors, super calls, instance
and static methods. The samples included in this demo are:
</p>
<p>
<ul>
<li>Creating a new class (declaration-form)</li>
<li>Creating a new class (expression-form)</li>
<li>Extending an existing class</li>
<li>Subclassing methods of a parent class</li>
<li>Defining static methods</li>
<li>Subclassing built-ins</li>
</ul>
</p>
{% include output_helper.html %}
{% include js_snippet.html filename='demo.js' %}