Can't work with backbone

Topics: General
Apr 28, 2014 at 6:19 AM
    constructor(options?) {
        this.events = {
            "click button.select": "select"
        };
        super(options);
    }
User backbone with typescript, super must call after this.events ready.and the todomvc demo is also call after events defined.but i got an error from typescript.if calling super not the first .it can't complier,so i can't use backbone with ts
Apr 28, 2014 at 7:58 AM
There is already a request for this: https://typescript.codeplex.com/workitem/91
Apr 28, 2014 at 4:41 PM
I believe you can convert "events" into a method to workaround that issue. When we switched from CoffeeScript to TypeScript we hit a bunch of these issues. The workarounds are documented here: https://github.com/palantir/coffeescript-to-typescript#backbone-notes