mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
work on composability
This commit is contained in:
+2
-2
@@ -44,6 +44,8 @@ export default class Widget {
|
||||
|
||||
async mount(target: HTMLElement) {
|
||||
await this.willStart();
|
||||
this.env!.qweb.addTemplate(this.name, this.template);
|
||||
delete this.template;
|
||||
await this.render();
|
||||
target.appendChild(this.el!);
|
||||
}
|
||||
@@ -56,8 +58,6 @@ export default class Widget {
|
||||
|
||||
setEnvironment(env: Env) {
|
||||
this.env = Object.create(env);
|
||||
env.qweb.addTemplate(this.name, this.template);
|
||||
delete this.template;
|
||||
}
|
||||
|
||||
async updateState(newState: Object) {
|
||||
|
||||
Reference in New Issue
Block a user