aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/template-renderer-proxy.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-01-10 19:28:50 -0500
committerGitHub <noreply@github.com>2021-01-10 19:28:50 -0500
commit4ed949364564f00a8b871095d030af516fc2ed6d (patch)
tree8a7ac38887874f67f2e99187f7ab3ce29496fe51 /ext/bg/js/template-renderer-proxy.js
parent25080ac82eef83fdaa921e2a8b12261130b8ac85 (diff)
Refactor anki note building (#1223)
* Move TemplateRendererProxy creation into AnkiNoteBuilder * Simplify _stringReplaceAsync * Organize note generation * Rename API * Make the template rendering function more generic
Diffstat (limited to 'ext/bg/js/template-renderer-proxy.js')
-rw-r--r--ext/bg/js/template-renderer-proxy.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/bg/js/template-renderer-proxy.js b/ext/bg/js/template-renderer-proxy.js
index 04b53ce7..21d45a94 100644
--- a/ext/bg/js/template-renderer-proxy.js
+++ b/ext/bg/js/template-renderer-proxy.js
@@ -25,9 +25,9 @@ class TemplateRendererProxy {
this._invocations = new Set();
}
- async render(template, data, marker) {
+ async render(template, data, type) {
await this._prepareFrame();
- return await this._invoke('renderHandlebarsTemplate', {template, data, marker});
+ return await this._invoke('render', {template, data, type});
}
// Private