表情符号显示为原始 HTML 代码

Emoticons displayed as raw HTML code

我正在使用 Meteor (https://atmospherejs.com/mattimo/emoticons) 中的 mattimo:emoticons 包来显示表情符号。我正在使用这个简单的模板来测试它:

    <template name="test">
      {{parseEmoticons ":-)"}}
    </template>

通过路由“/test”显示,如下所示:

    Router.route('/test/', function () {
      this.render("test");
    });

这应该显示一个简单的笑脸,但我在浏览器中得到的是原始 HTML:

    <img class="meteoremoticon" src="/packages/mattimo_emoticons/assets/images/emoticons/caritas_07.png">

如何让浏览器呈现 HTML 而不是只显示未处理的 HTML?

来自Meteor documentation

{{{content}}} - Triple-braced template tags are used to insert raw HTML. Be careful with these! It's your job to make sure the HTML is safe, either by generating it yourself or sanitizing it if it came from a user input.

所以,尝试使用三重大括号

<template name="test">
  {{{ parseEmoticons ":-)" }}}
</template>