mirror of
https://github.com/meld-cp/obsidian-build.git
synced 2026-07-22 07:30:25 +00:00
remove await $.render from docs
This commit is contained in:
parent
b1d641077d
commit
328982dbe5
2 changed files with 3 additions and 3 deletions
|
|
@ -109,7 +109,7 @@ const customer = customers.filter( e => e.id==inv.customer ).at(0);
|
|||
const template = $.blocks.at(0);
|
||||
|
||||
// render the template passing in the customer and invoice
|
||||
const html = await $.render( template, { customer, inv } );
|
||||
const html = $.render( template, { customer, inv } );
|
||||
|
||||
// create an html invoice file and open it in the default browser, from there it can be saved as a PDF
|
||||
await $.io.output( `inv ${inv.id}.html`, html, true );
|
||||
|
|
|
|||
|
|
@ -87,7 +87,7 @@ Here's an example:
|
|||
const mytemplate = 'Hello {{name}}';
|
||||
const mydata = { name:'World' };
|
||||
|
||||
const result = await $.render( mytemplate, mydata );
|
||||
const result = $.render( mytemplate, mydata );
|
||||
|
||||
await $.ui.message( result );
|
||||
```
|
||||
|
|
@ -109,7 +109,7 @@ The meld-build block to run:
|
|||
const template = $.blocks.at(0); // gets the first non-meld-build block in the note
|
||||
const data = { name:'John', message:'How are you?' };
|
||||
|
||||
const result = await $.render( template, data );
|
||||
const result = $.render( template, data );
|
||||
|
||||
await $.ui.message( result );
|
||||
```
|
||||
|
|
|
|||
Loading…
Reference in a new issue