Skip to content

Manifest 使用 ​

本文档详细介绍如何在 manifest.yaml 文件中使用多语言。

使用 ​

在 manifest.yaml 文件中,支持通过 i18n 字段声明多语言资源 key,用于动态解析不同语言下的展示内容:

javascript
extensions:
  - key: hello-world-project-hub
    title: 
      i18n: page.title
    target: "pcm:pjm:project:page"
    resource: main
    resolver:
      function: resolver

运行时系统会根据当前语言环境自动将 i18n 对应的 key 解析为具体文案,例如:

  • zh-CN → 页面标题
  • en-US → Page Title

参考引用 ​

举报邮箱:abuse@worktile.com