Typescript Class Inheritance

I had a question regarding inheritance in typescript.

So given code like: http://webix.com/snippet/5bbe941a

Is there any way to get around the call to webix.extend? Because it seems like it should already be extending webix.ui.layout due to the call to super(). Also, I get an error when trying to run it in the browser saying this (callstack included)

15:24:42.745 TypeError: config is undefined 1 webix_debug.js:4736:7
.$init http://localhost:8080/lib/webix/codebase/webix_debug.js:4736:7
webix.proto/compilation.$init http://localhost:8080/lib/webix/codebase/webix_debug.js:222:4
webix.proto/compilation.$init http://localhost:8080/lib/webix/codebase/webix_debug.js:222:4
webix.proto/compilation.$init http://localhost:8080/lib/webix/codebase/webix_debug.js:222:4
webix.proto/result http://localhost:8080/lib/webix/codebase/webix_debug.js:230:3
Foo http://localhost:8080/bin/app.js:23:25
main/< http://localhost:8080/bin/app.js:35:22
doit http://localhost:8080/lib/webix/codebase/webix_debug.js:1058:4
webix.delay/< http://localhost:8080/lib/webix/codebase/webix_debug.js:352:14

If I omit the super() and inheritance like this: http://webix.com/snippet/2bba9674 everything works just fine, but now I’ve lost all ability for my editor and typescript to resolve methods and properties available on the layout class. Is there some magic method that I need to call or property I need to set for this to work?

Hi,

Nope, you still need to call webix.protoUI to define a new view. Webix was written for classic javascript, so it can’t operate with native javascript classes.

Also, webix.ui expects a declarative UI configuration not a live objects.

webix.protoUI({
  name:"Foo",
}, webix.ui.layout);

webix.ui({ view:"Foo" });