IssueRaiser

Request: Class Decorator Mutation

If we can get this to type check properly, we would have perfect support for boilerplate-free mixins: ``` typescript declare function Blah<T>(target: T): T & {foo: number} @Blah class Foo { bar() { return this.foo; // Property 'foo' does not exist on type 'Foo' } } new Foo().foo; // Property 'foo' does not exist on type 'Foo' ```

Posted by Gaelan on Sep 20, 2015, 6:05 AM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.5,000 issues0 comments

support (Other)

Request: Class Decorator Mutation

GaelanSep 20, 2015, 6:05 AM

If we can get this to type check properly, we would have perfect support for boilerplate-free mixins: ``` typescript declare function Blah<T>(target: T): T & {foo: number} @Blah class Foo { bar() { return this.foo; // Property 'foo' does not exist on type 'Foo' } } new Foo().foo; // Property 'foo' does not exist on type 'Foo' ```

Comments (0)

No comments yet. Start the discussion.

Comment on this issue