When a cell is created as hidden, the ready
function is never called in the view.
For example:
import { Toolbar } from "./Toolbar";
import { View } from "dhx-optimus";
export class TopLayout extends View {
init() {
return this.layout = new dhx.Layout(null, {
rows: [
{ id: "toolbar", hidden: true, height: 56, init: cell => this.show(cell, Toolbar)},
]
})
}
ready() {
console.log("TopLayout ready")
setTimeout(()=> {
this.layout.getCell("toolbar").show()
}, 1000)
}
Now in Toolbar.js we have:
import {View} from "dhx-optimus";
export class Toolbar extends View {
init() {
return new dhx.Toolbar(null, {
data: [
{type: "navItem", value: "My NavItem"}
]
});
}
ready() {
console.log("Toolbar Ready")
}
}
We can see the content of Toolbar view but console.log("Toolbar Ready")
was never called.