Function
Optional
The key name of the tool in the MVC instance (if any). By default, it is inferred from the name of the field. If the field is named somethingTool, the key name will be something.
somethingTool
something
tool
Stage-3 field decorator for MVC structure. It reduces code by turning the decorated field into a fetched tool.
@tool() protected textTool: TurboTool; Copy
@tool() protected textTool: TurboTool;
Is equivalent to:
protected get textTool(): TurboTool { if (this.mvc instanceof Mvc) return this.mvc.getTool("text"); if (typeof this.getTool === "function") return this.getTool("text");} Copy
protected get textTool(): TurboTool { if (this.mvc instanceof Mvc) return this.mvc.getTool("text"); if (typeof this.getTool === "function") return this.getTool("text");}
The key name of the tool in the MVC instance (if any). By default, it is inferred from the name of the field. If the field is named
somethingTool, the key name will besomething.