mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
[IMP] qweb: slightly simplify generated templates
- In some cases, we can simply inline a template key instead of assigning it to a variable and then using that variable - Add component name in generated code for components
This commit is contained in:
@@ -189,7 +189,7 @@ QWeb.addDirective({
|
||||
extraNames: ["props"],
|
||||
priority: 100,
|
||||
atNodeEncounter({ ctx, value, node, qweb }): boolean {
|
||||
ctx.addLine("//COMPONENT");
|
||||
ctx.addLine(`// Component '${value}'`);
|
||||
ctx.rootContext.shouldDefineQWeb = true;
|
||||
ctx.rootContext.shouldDefineParent = true;
|
||||
ctx.rootContext.shouldDefineUtils = true;
|
||||
|
||||
Reference in New Issue
Block a user