summaryrefslogtreecommitdiff
path: root/ext/bg/js/yomichan.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2016-09-12 22:14:58 -0700
committerAlex Yatskov <alex@foosoft.net>2016-09-12 22:14:58 -0700
commit540d0e239c9b7dc5bee8a3e53bcf6ec0767ee80b (patch)
tree559fe79c76faa13610d745036e3e0864a7f40857 /ext/bg/js/yomichan.js
parent4241b4f8595813b966371a02f5b2f35d7997b1e2 (diff)
Cleanup
Diffstat (limited to 'ext/bg/js/yomichan.js')
-rw-r--r--ext/bg/js/yomichan.js13
1 files changed, 1 insertions, 12 deletions
diff --git a/ext/bg/js/yomichan.js b/ext/bg/js/yomichan.js
index d9d4234d..26b28138 100644
--- a/ext/bg/js/yomichan.js
+++ b/ext/bg/js/yomichan.js
@@ -20,18 +20,7 @@
class Yomichan {
constructor() {
Handlebars.partials = Handlebars.templates;
- Handlebars.registerHelper('kanjiLinks', function(options) {
- let result = '';
- for (const c of options.fn(this)) {
- if (isKanji(c)) {
- result += Handlebars.templates['kanji-link.html']({kanji: c}).trim();
- } else {
- result += c;
- }
- }
-
- return result;
- });
+ Handlebars.registerHelper('kanjiLinks', kanjiLinks);
this.translator = new Translator();
this.asyncPools = {};