UNPKG

15.7 kBJavaScriptView Raw
1const typedArrayMethods = [
2 "typed arrays / %TypedArray%.from",
3 "typed arrays / %TypedArray%.of",
4 "typed arrays / %TypedArray%.prototype.subarray",
5 "typed arrays / %TypedArray%.prototype.join",
6 "typed arrays / %TypedArray%.prototype.indexOf",
7 "typed arrays / %TypedArray%.prototype.lastIndexOf",
8 "typed arrays / %TypedArray%.prototype.slice",
9 "typed arrays / %TypedArray%.prototype.every",
10 "typed arrays / %TypedArray%.prototype.filter",
11 "typed arrays / %TypedArray%.prototype.forEach",
12 "typed arrays / %TypedArray%.prototype.map",
13 "typed arrays / %TypedArray%.prototype.reduce",
14 "typed arrays / %TypedArray%.prototype.reduceRight",
15 "typed arrays / %TypedArray%.prototype.reverse",
16 "typed arrays / %TypedArray%.prototype.some",
17 "typed arrays / %TypedArray%.prototype.sort",
18 "typed arrays / %TypedArray%.prototype.copyWithin",
19 "typed arrays / %TypedArray%.prototype.find",
20 "typed arrays / %TypedArray%.prototype.findIndex",
21 "typed arrays / %TypedArray%.prototype.fill",
22 "typed arrays / %TypedArray%.prototype.keys",
23 "typed arrays / %TypedArray%.prototype.values",
24 "typed arrays / %TypedArray%.prototype.entries",
25 "typed arrays / %TypedArray%.prototype[Symbol.iterator]",
26 "typed arrays / %TypedArray%[Symbol.species]",
27];
28
29const es = {
30 // compat-table missing babel6 mapping
31 // "es6.array.concat": {
32 // features: [
33 // "well-known symbols / Symbol.isConcatSpreadable",
34 // "well-known symbols / Symbol.species, Array.prototype.concat",
35 // ]
36 // },
37 "es6.array.copy-within": "Array.prototype methods / Array.prototype.copyWithin",
38 "es6.array.every": "Array methods / Array.prototype.every",
39 "es6.array.fill": "Array.prototype methods / Array.prototype.fill",
40 "es6.array.filter": {
41 features: [
42 "Array methods / Array.prototype.filter",
43 // compat-table missing babel6 mapping
44 // "well-known symbols / Symbol.species, Array.prototype.filter",
45 ],
46 },
47 "es6.array.find": "Array.prototype methods / Array.prototype.find",
48 "es6.array.find-index": "Array.prototype methods / Array.prototype.findIndex",
49 "es7.array.flat-map": "Array.prototype.{flat, flatMap} / Array.prototype.flatMap",
50 "es6.array.for-each": "Array methods / Array.prototype.forEach",
51 "es6.array.from": "Array static methods / Array.from",
52 "es7.array.includes": "Array.prototype.includes",
53 "es6.array.index-of": "Array methods / Array.prototype.indexOf",
54 "es6.array.is-array": "Array methods / Array.isArray",
55 // "es.array.join": "", required tests for that
56 "es6.array.iterator": {
57 features: [
58 "Array.prototype methods / Array.prototype.keys",
59 // can use Symbol.iterator, not implemented in many environments
60 // "Array.prototype methods / Array.prototype.values",
61 "Array.prototype methods / Array.prototype.entries",
62 ],
63 },
64 "es6.array.last-index-of": "Array methods / Array.prototype.lastIndexOf",
65 "es6.array.map": {
66 features: [
67 "Array methods / Array.prototype.map",
68 // compat-table missing babel6 mapping
69 // "well-known symbols / Symbol.species, Array.prototype.map",
70 ],
71 },
72 "es6.array.of": "Array static methods / Array.of",
73 "es6.array.reduce": "Array methods / Array.prototype.reduce",
74 "es6.array.reduce-right": "Array methods / Array.prototype.reduceRight",
75 // compat-table missing babel6 mapping
76 // "es6.array.slice": "well-known symbols / Symbol.species, Array.prototype.slice",
77 "es6.array.some": "Array methods / Array.prototype.some",
78 "es6.array.sort": "Array methods / Array.prototype.sort",
79 "es6.array.species": "Array static methods / Array[Symbol.species]",
80 // compat-table missing babel6 mapping
81 //"es6.array.splice": "well-known symbols / Symbol.species, Array.prototype.splice",
82
83 "es6.date.now": "Date methods / Date.now",
84 "es6.date.to-iso-string": "Date methods / Date.prototype.toISOString",
85 "es6.date.to-json": "Date methods / Date.prototype.toJSON",
86 "es6.date.to-primitive": "Date.prototype[Symbol.toPrimitive]",
87 "es6.date.to-string": "miscellaneous / Invalid Date",
88
89 "es6.function.bind": "Function.prototype.bind",
90 "es6.function.has-instance": "well-known symbols / Symbol.hasInstance",
91 "es6.function.name": {
92 features: [
93 "function \"name\" property / function statements",
94 "function \"name\" property / function expressions",
95 ],
96 },
97
98 "es6.map": "Map",
99
100 "es6.math.acosh": "Math methods / Math.acosh",
101 "es6.math.asinh": "Math methods / Math.asinh",
102 "es6.math.atanh": "Math methods / Math.atanh",
103 "es6.math.cbrt": "Math methods / Math.cbrt",
104 "es6.math.clz32": "Math methods / Math.clz32",
105 "es6.math.cosh": "Math methods / Math.cosh",
106 "es6.math.expm1": "Math methods / Math.expm1",
107 "es6.math.fround": "Math methods / Math.fround",
108 "es6.math.hypot": "Math methods / Math.hypot",
109 "es6.math.imul": "Math methods / Math.imul",
110 "es6.math.log1p": "Math methods / Math.log1p",
111 "es6.math.log10": "Math methods / Math.log10",
112 "es6.math.log2": "Math methods / Math.log2",
113 "es6.math.sign": "Math methods / Math.sign",
114 "es6.math.sinh": "Math methods / Math.sinh",
115 "es6.math.tanh": "Math methods / Math.tanh",
116 "es6.math.trunc": "Math methods / Math.trunc",
117
118 "es6.number.constructor": {
119 features: [
120 "octal and binary literals / octal supported by Number()",
121 "octal and binary literals / binary supported by Number()",
122 ],
123 },
124 "es6.number.epsilon": "Number properties / Number.EPSILON",
125 "es6.number.is-finite": "Number properties / Number.isFinite",
126 "es6.number.is-integer": "Number properties / Number.isInteger",
127 "es6.number.is-nan": "Number properties / Number.isNaN",
128 "es6.number.is-safe-integer": "Number properties / Number.isSafeInteger",
129 "es6.number.max-safe-integer": "Number properties / Number.MAX_SAFE_INTEGER",
130 "es6.number.min-safe-integer": "Number properties / Number.MIN_SAFE_INTEGER",
131 "es6.number.parse-float": "Number properties / Number.parseFloat",
132 "es6.number.parse-int": "Number properties / Number.parseInt",
133
134 "es6.object.assign": {
135 features: ["Object static methods / Object.assign", "Symbol"],
136 },
137 "es6.object.create": "Object static methods / Object.create",
138 "es7.object.define-getter": {
139 features: [
140 "Object.prototype getter/setter methods / __defineGetter__",
141 "Object.prototype getter/setter methods / __defineGetter__, symbols",
142 "Object.prototype getter/setter methods / __defineGetter__, ToObject(this)",
143 ],
144 },
145 "es7.object.define-setter": {
146 features: [
147 "Object.prototype getter/setter methods / __defineSetter__",
148 "Object.prototype getter/setter methods / __defineSetter__, symbols",
149 "Object.prototype getter/setter methods / __defineSetter__, ToObject(this)",
150 ],
151 },
152 "es6.object.define-property": "Object static methods / Object.defineProperty",
153 "es6.object.define-properties": "Object static methods / Object.defineProperties",
154 "es7.object.entries": "Object static methods / Object.entries",
155 "es6.object.freeze": "Object static methods accept primitives / Object.freeze",
156 "es6.object.get-own-property-descriptor": "Object static methods accept primitives / Object.getOwnPropertyDescriptor",
157 "es7.object.get-own-property-descriptors": "Object static methods / Object.getOwnPropertyDescriptors",
158 "es6.object.get-own-property-names": "Object static methods accept primitives / Object.getOwnPropertyNames",
159 "es6.object.get-prototype-of": "Object static methods accept primitives / Object.getPrototypeOf",
160 "es7.object.lookup-getter": {
161 features: [
162 "Object.prototype getter/setter methods / __lookupGetter__",
163 "Object.prototype getter/setter methods / __lookupGetter__, prototype chain",
164 "Object.prototype getter/setter methods / __lookupGetter__, symbols",
165 "Object.prototype getter/setter methods / __lookupGetter__, ToObject(this)",
166 "Object.prototype getter/setter methods / __lookupGetter__, data properties can shadow accessors",
167 ],
168 },
169 "es7.object.lookup-setter": {
170 features: [
171 "Object.prototype getter/setter methods / __lookupSetter__",
172 "Object.prototype getter/setter methods / __lookupSetter__, prototype chain",
173 "Object.prototype getter/setter methods / __lookupSetter__, symbols",
174 "Object.prototype getter/setter methods / __lookupSetter__, ToObject(this)",
175 "Object.prototype getter/setter methods / __lookupSetter__, data properties can shadow accessors",
176 ],
177 },
178 "es6.object.prevent-extensions": "Object static methods accept primitives / Object.preventExtensions",
179 "es6.object.to-string": "well-known symbols / Symbol.toStringTag",
180 "es6.object.is": "Object static methods / Object.is",
181 "es6.object.is-frozen": "Object static methods accept primitives / Object.isFrozen",
182 "es6.object.is-sealed": "Object static methods accept primitives / Object.isSealed",
183 "es6.object.is-extensible": "Object static methods accept primitives / Object.isExtensible",
184 "es6.object.keys": "Object static methods accept primitives / Object.keys",
185 "es6.object.seal": "Object static methods accept primitives / Object.seal",
186 "es6.object.set-prototype-of": "Object static methods / Object.setPrototypeOf",
187 "es7.object.values": "Object static methods / Object.values",
188
189 "es6.promise": {
190 features: [
191 // required unhandled rejection tracking tests
192 "Promise",
193 "well-known symbols / Symbol.species, Promise.prototype.then",
194 ],
195 },
196 "es7.promise.finally": "Promise.prototype.finally",
197
198 "es6.reflect.apply": "Reflect / Reflect.apply",
199 "es6.reflect.construct": "Reflect / Reflect.construct",
200 "es6.reflect.define-property": "Reflect / Reflect.defineProperty",
201 "es6.reflect.delete-property": "Reflect / Reflect.deleteProperty",
202 "es6.reflect.get": "Reflect / Reflect.get",
203 "es6.reflect.get-own-property-descriptor": "Reflect / Reflect.getOwnPropertyDescriptor",
204 "es6.reflect.get-prototype-of": "Reflect / Reflect.getPrototypeOf",
205 "es6.reflect.has": "Reflect / Reflect.has",
206 "es6.reflect.is-extensible": "Reflect / Reflect.isExtensible",
207 "es6.reflect.own-keys": "Reflect / Reflect.ownKeys",
208 "es6.reflect.prevent-extensions": "Reflect / Reflect.preventExtensions",
209 "es6.reflect.set": "Reflect / Reflect.set",
210 "es6.reflect.set-prototype-of": "Reflect / Reflect.setPrototypeOf",
211
212 "es6.regexp.constructor": {
213 features: [
214 "miscellaneous / RegExp constructor can alter flags",
215 "well-known symbols / Symbol.match, RegExp constructor",
216 ],
217 },
218 "es6.regexp.flags": "RegExp.prototype properties / RegExp.prototype.flags",
219 "es6.regexp.match": "RegExp.prototype properties / RegExp.prototype[Symbol.match]",
220 "es6.regexp.replace": "RegExp.prototype properties / RegExp.prototype[Symbol.replace]",
221 "es6.regexp.split": "RegExp.prototype properties / RegExp.prototype[Symbol.split]",
222 "es6.regexp.search": "RegExp.prototype properties / RegExp.prototype[Symbol.search]",
223 "es6.regexp.to-string": "miscellaneous / RegExp.prototype.toString generic and uses \"flags\" property",
224
225 // This is explicit due to prevent the stage-1 Set proposals under the
226 // category "Set methods" from being included.
227 "es6.set": {
228 features: [
229 "Set / basic functionality",
230 "Set / constructor arguments",
231 "Set / constructor requires new",
232 "Set / constructor accepts null",
233 "Set / constructor invokes add",
234 "Set / iterator closing",
235 "Set / Set.prototype.add returns this",
236 "Set / -0 key converts to +0",
237 "Set / Set.prototype.size",
238 "Set / Set.prototype.delete",
239 "Set / Set.prototype.clear",
240 "Set / Set.prototype.forEach",
241 "Set / Set.prototype.keys",
242 "Set / Set.prototype.values",
243 "Set / Set.prototype.entries",
244 "Set / Set.prototype[Symbol.iterator]",
245 "Set / Set.prototype isn't an instance",
246 "Set / Set iterator prototype chain",
247 "Set / Set[Symbol.species]",
248 ],
249 },
250
251 "es6.symbol": {
252 features: [
253 "Symbol",
254 "Object static methods / Object.getOwnPropertySymbols",
255 "well-known symbols / Symbol.hasInstance",
256 "well-known symbols / Symbol.isConcatSpreadable",
257 "well-known symbols / Symbol.iterator",
258 "well-known symbols / Symbol.match",
259 "well-known symbols / Symbol.replace",
260 "well-known symbols / Symbol.search",
261 "well-known symbols / Symbol.species",
262 "well-known symbols / Symbol.split",
263 "well-known symbols / Symbol.toPrimitive",
264 "well-known symbols / Symbol.toStringTag",
265 "well-known symbols / Symbol.unscopables",
266 ],
267 },
268 "es7.symbol.async-iterator": "Asynchronous Iterators",
269
270 "es6.string.anchor": "String.prototype HTML methods",
271 "es6.string.big": "String.prototype HTML methods",
272 "es6.string.blink": "String.prototype HTML methods",
273 "es6.string.bold": "String.prototype HTML methods",
274 "es6.string.code-point-at": "String.prototype methods / String.prototype.codePointAt",
275 "es6.string.ends-with": "String.prototype methods / String.prototype.endsWith",
276 "es6.string.fixed": "String.prototype HTML methods",
277 "es6.string.fontcolor": "String.prototype HTML methods",
278 "es6.string.fontsize": "String.prototype HTML methods",
279 "es6.string.from-code-point": "String static methods / String.fromCodePoint",
280 "es6.string.includes": "String.prototype methods / String.prototype.includes",
281 "es6.string.italics": "String.prototype HTML methods",
282 "es6.string.iterator": "String.prototype methods / String.prototype[Symbol.iterator]",
283 "es6.string.link": "String.prototype HTML methods",
284 // "String.prototype methods / String.prototype.normalize" not implemented
285 "es7.string.pad-start": "String padding / String.prototype.padStart",
286 "es7.string.pad-end": "String padding / String.prototype.padEnd",
287 "es6.string.raw": "String static methods / String.raw",
288 "es6.string.repeat": "String.prototype methods / String.prototype.repeat",
289 "es6.string.small": "String.prototype HTML methods",
290 "es6.string.starts-with": "String.prototype methods / String.prototype.startsWith",
291 "es6.string.strike": "String.prototype HTML methods",
292 "es6.string.sub": "String.prototype HTML methods",
293 "es6.string.sup": "String.prototype HTML methods",
294 "es6.string.trim": "String properties and methods / String.prototype.trim",
295 "es7.string.trim-left": "string trimming / String.prototype.trimStart",
296 "es7.string.trim-right": "string trimming / String.prototype.trimEnd",
297
298 "es6.typed.array-buffer": "typed arrays / ArrayBuffer[Symbol.species]",
299 "es6.typed.data-view": "typed arrays / DataView",
300 "es6.typed.int8-array": {
301 features: ["typed arrays / Int8Array"].concat(typedArrayMethods),
302 },
303 "es6.typed.uint8-array": {
304 features: ["typed arrays / Uint8Array"].concat(typedArrayMethods),
305 },
306 "es6.typed.uint8-clamped-array": {
307 features: ["typed arrays / Uint8ClampedArray"].concat(typedArrayMethods),
308 },
309 "es6.typed.int16-array": {
310 features: ["typed arrays / Int16Array"].concat(typedArrayMethods),
311 },
312 "es6.typed.uint16-array": {
313 features: ["typed arrays / Uint16Array"].concat(typedArrayMethods),
314 },
315 "es6.typed.int32-array": {
316 features: ["typed arrays / Int32Array"].concat(typedArrayMethods),
317 },
318 "es6.typed.uint32-array": {
319 features: ["typed arrays / Uint32Array"].concat(typedArrayMethods),
320 },
321 "es6.typed.float32-array": {
322 features: ["typed arrays / Float32Array"].concat(typedArrayMethods),
323 },
324 "es6.typed.float64-array": {
325 features: ["typed arrays / Float64Array"].concat(typedArrayMethods),
326 },
327
328 "es6.weak-map": "WeakMap",
329
330 "es6.weak-set": "WeakSet",
331};
332
333const proposals = require("./shipped-proposals").builtIns;
334
335module.exports = Object.assign({}, es, proposals);