-
-
Notifications
You must be signed in to change notification settings - Fork 195
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ECMAScript 6 features #10
Comments
The |
In order to make the regular expression flags work, I needed to add a |
New: Add u and y regex flags (refs #10)
New: Add support for object literal method shorthand (refs #10)
New: Add support for shorthand properties (refs #10)
@nzakas which of these would you reccomend to get started on? |
I think allowing duplicate properties in strict mode is the easiest to get started with. I'd call that After that, Unicode code point escapes (see https://leanpub.com/understandinges6/read#leanpub-auto-better-unicode-support) |
I'm currently working on generators. |
I'm starting work on Unicode code point escapes |
Generators and code point escapes have been merged in. |
Next priority is template literals. @FredKSchott interested in taking that? |
definitely, I'll tackle that next (away for the long weekend but I'll take a look next week) They're supported in V8 now, right? Makes sense to do them next |
Yup! And also in io.js now. I'm planning on attacking arrow functions when I have some energy. |
facebook/esprima supports classes. |
Esprima classes support: jquery/esprima#1061 |
Well that makes things easier :) |
Working on classes now. |
👏 |
you guys are killing it 👏 👏 👏 |
Ran into a bit of trouble with classes. The Harmony branch is different that Esprima's master now (master being the most correct). Will probably take me a bit to work through it unless someone else wants to give it a shot. |
I'm still trying to grok the destructuring defaults spec. Once I'm done with that I'll try to throw my hat into either classes or modules. Whatever's left.... |
Fast work on getting these es6 features implemented! I noticed an issue with rest parameters though, they don't seem to get added to the scope's variable list. I noticed this when trying to use eslint to validate a function with rest parameters. var func = function (first, ...rest) {
return rest;
}; I am getting a 'rest' is not defined (no-undef) error. The underlying cause seems to be that when the rule's function looks at context.getScope().variables, a variable named 'rest' is not in the list. see eslint/eslint#1870 to fully replicate |
Cool just saw eslint/eslint#1870. |
As I mentioned there, this is an issue with escope, not espree. |
Don't look now, modules is the last feature! |
should we file a separate bug just for the modules support? In this related bug I posted an example of how espree differs from esprima when used with escope eslint/eslint#1978 (comment) |
Modules are already properly supported. |
This is a rollup that will let us keep track of ES6 progress.
let
declarationsconst
declarationsu
flagy
flagsuper
referencesfor-of
loops__proto__
)The text was updated successfully, but these errors were encountered: