eclipse-typescript
eclipse-typescript copied to clipboard
Add support for emitDecoratorMetadata compiler option
I try to use the plugin for angular 2. I would like to set moduleResolution, emitDecoratorMetadata, experimentalDecorators. Is there some possibility to set these? Is it possible for extend the plugin to support the params. Where could I start?
Looks like experimentalDecorators and moduleResolution are already supported (its in the project settings for a TypeScript-enabled project). The emitDecoratorMetadata support is missing. If you are interested in contributing this back, check out https://github.com/palantir/eclipse-typescript/commit/5caabc641eef9bf0b8310b392e1364deaabd1770 for an example of hooking up a compiler option.
Apparently, this little compiler option is a pretty big deal in the world of Angular2 and Dependency Injection (@Injectable). After two days of banging my head against the wall and wondering why DI was throwing exceptions (TypeError: Cannot read property 'query' of null in RC2 and Can't resolve all parameters for ...: (?, ?) in RC4 ), I came across this open issue.
Anyway, I could definitely use this option in the future, however, it appears this coincides a bit with Issue #268 and is currently being addressed with PR #323, so having tsconfig support would be an amazing short term "workaround" for me!
Thanks @JustinCIS, #323 PR should be checked by the end of the week.
I added emitDecoratorMetadata option in this commit: 3762c20