olov / ng-annotate

Add, remove and rebuild AngularJS dependency injection annotations
MIT License
2.03k stars 150 forks source link

Support for arrow function #240

Closed pioug closed 8 years ago

pioug commented 8 years ago

I would like to add support for ES6 arrow function.

As far as I know, the modification is not big since ArrowFunctionExpression and FunctionExpression structures are quite similar. The only difference I think of is the case of a body without curly brace like in x => x instead of x => { return x; }.

My little contributtion towards ES6 support https://github.com/olov/ng-annotate/issues/237

olov commented 8 years ago

https://github.com/olov/ng-annotate/issues/245

schmod commented 8 years ago

Fixed in babel-plugin-angularjs-annotate: https://github.com/schmod/babel-plugin-angularjs-annotate/commit/7cdc9c39be166ccd9ea208e83cdf91b613cdf55d

olov commented 8 years ago

245