mirror of
https://github.com/discourse/discourse.git
synced 2025-02-24 23:49:38 +08:00

Since 0fa92529ed, helpers can now be implemented as plain JS functions. This makes them much easier to write/read, and also makes them usable in `<template>` gjs files.
7 lines
163 B
JavaScript
7 lines
163 B
JavaScript
import I18n from "I18n";
|
|
import { htmlSafe } from "@ember/template";
|
|
|
|
export default function boundI18n(key, options) {
|
|
return htmlSafe(I18n.t(key, options));
|
|
}
|