Webix Jet - Promises doesn't work with classes

Hi!

I've this class:

export default class SomeView extends JetView {
config(){
return webix.ajax("/").then(_ => ({template: "Hello"}));
}
}

And the view doesn´t render :(.

This works if I do

export default webix.ajax("/").then(_ => ({template: "Hello"}));

Someone knows why it doesn't work?

Thanks!

Comments

  • you need to return a class in promise

    export default webix.ajax("/").then(_ => (class SomeView extends JetView {...}}));
    
  • edited November 2017

    The problem is when I do an export default class, not when I do a export default .

    When I return a promise, the code works OK

  • Same problem for me. Any solution?

  • Webix Jet was updated to version 1.1
    Now it possible to return promise from the config method.

Sign In or Register to comment.