generated from cms/tibi-docs
backend & types
This commit is contained in:
@@ -1,23 +0,0 @@
|
||||
## tpl
|
||||
|
||||
Das TplPackage-Interface bietet Funktionen zur Ausführung von Template-Code. Es enthält folgende Methode:
|
||||
|
||||
`execute(code: string, contextData?: { [key: string]: any }): string`:
|
||||
Diese Methode nimmt einen Template-Code und optionale Kontextdaten entgegen und gibt das Ergebnis der Template-Ausführung als String zurück. Mit dieser Methode können Sie dynamischen Code ausführen und das Ergebnis in Ihrem Programm verwenden. Genutzt wird dies meist um E-Mail templates zu rendern.
|
||||
|
||||
```ts
|
||||
interface TplPackage {
|
||||
/**
|
||||
* execute a template code and return result
|
||||
*
|
||||
* @param code template code
|
||||
* @param contextData template context map
|
||||
*/
|
||||
execute(
|
||||
code: string,
|
||||
contextData?: {
|
||||
[key: string]: any
|
||||
}
|
||||
): string
|
||||
}
|
||||
```
|
||||
Reference in New Issue
Block a user