[IMP] component: add props validation and default props system

closes #116
This commit is contained in:
Géry Debongnie
2019-05-28 09:54:25 +02:00
parent a525b42537
commit 681983142d
4 changed files with 488 additions and 7 deletions
+1 -1
View File
@@ -490,7 +490,7 @@ QWeb.addDirective({
);
let keepAliveCode = "";
if (keepAlive) {
keepAliveCode = `pvnode.data.hook.insert = vn => {vn.elm.parentNode.replaceChild(w${widgetID}.el,vn.elm);vn.elm=w${widgetID}.el;w${widgetID}.__mount();};`;
keepAliveCode = `pvnode.data.hook.insert = vn => {vn.elm.parentNode.replaceChild(w${widgetID}.el,vn.elm);vn.elm=w${widgetID}.el;w${widgetID}._remount();};`;
}
ctx.addLine(
`def${defID} = def${defID}.then(()=>{if (w${widgetID}.__owl__.isDestroyed) {return};${