This repository was archived by the owner on Dec 15, 2022. It is now read-only.
This repository was archived by the owner on Dec 15, 2022. It is now read-only.
Recognize numeric literals in ES6 method definitions #410
Open
Description
These keys are valid but marked as "invalid illegal" with the current regex:
const obj = {
0() {},
0b101() {},
010() {},
80() {},
.12e3() {},
0o753() {},
12e34() {},
0xFFFF() {},
};
I came across the first one in my own code, which prompted me to look up the other potential ones here: https://mathiasbynens.be/notes/javascript-properties