您好,这是我喜欢使用的代码(使用 ionc +meteor),但我的 i18n key 没有被翻译。 在其他上下文中,翻译有效。
我需要做什么才能让这段代码正常工作?
{{>ionNavBackButton path="main" text="{{i18n 'backButton'}}"}}
目前我的后退按钮的标签是:“{{i18n 'backButton'}}”,但我喜欢根据区域设置为“Back”或“Zurück”。
最佳答案
我目前正在开发一个包含链接的帮助程序包。
在 meteor 论坛的讨论中了解更多相关信息:
https://forums.meteor.com/t/what-about-multiple-helper-calls-in-a-template-is-this-usefull/6815/2
<小时/>目前您还可以尝试:
{{#with i18n 'backButton}}
{{>ionNavBackButton path="main" text=this}}
{{/with}}
但这很烦人;-)
关于javascript - Meteor 中的嵌套助手? - 如何使用一个助手的输出作为另一助手的输入?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31404220/