discourse/app/assets/javascripts/discourse-common/addon/helpers/bound-i18n.js
Jarek Radosz 9bbd5efbec
DEV: Convert helpers into plain functions (#22385)
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.
2023-07-20 19:45:40 +01:00

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));
}