experience-ui-bundle-localize
БесплатноЗапускает вложенные скриптыНе проверенMUST activate to localize / internationalize a uiBundles/*/src/ project (React or Angular): extract hardcoded user-facing strings into Custom Labels, wire a…
от forcedotcom★ 1 200 звёзд на GitHubОб этом скилле
Localize a UI Bundle
Localize a UI Bundle: extract user-facing strings into Salesforce Custom Labels, wire a runtime i18n library over the Platform SDK backend, and verify labels across locales.
This file is the framework-neutral workflow + guardrail spine. The framework-specific detail — which i18n library, the translation call convention, the files scanned, the wiring shape, and the depth docs — lives in a per-framework reference.
The one-paragraph mental model
A UI Bundle can't use compile-time label imports the way LWC does (@salesforce/label/*
resolves inside the platform's compiler, which your standalone bundle doesn't go through).
Instead, your app fetches labels at runtime through the Salesforce GraphQL UI API and
hands them to a standard i18n library to render. The Platform SDK provides the runtime
plumbing: a detector that reads the user's language, a backend that fetches labels over
GraphQL, and a context fetch. You write two thin files — a short init that wires the SDK
pieces into your i18n library, and a manifest listing which labels your app uses — then
author the labels themselves as Salesforce Custom Labels metadata. The exact library and
call convention are framework-specific; see your framework reference.
Step 0: Route the task
| The task is… | Go to |
|---|---|
| Bundle doesn't exist yet | experience-ui-bundle-frontend-generate skill |
| Deploying the app with its labels | experience-ui-bundle-deploy skill |
Configuring site languages or sfdc_cms__languageSettings |
experience-ui-bundle-site-generate skill |
| Localizing an existing bundle | Determine the framework (below), then the workflow |
Determine the framework. It is normally already decided by the calling context — passed down by the coordinator skill that invoked this one, or stated in the user's request. Use that.
The frameworks this skill supports are exactly the reference folders under
<SKILL_DIR>/references/, each containing a localize.md (so react →
<SKILL_DIR>/references/react/localize.md). This is the single source of truth — adding a
framework means adding a reference folder, nothing here changes.
If the framework is known — open
<SKILL_DIR>/references/<framework>/localize.mdand keep it alongside this spine. It supplies the library, the call convention, the files to scan, and the wiring code.If it is unknown (a standalone run where nobody said which) — run the deterministic detector on the app / uiBundle root before asking anyone:
bash "<SKILL_DIR>/scripts/detect-framework.sh" "<app-or-uiBundle-root>"It combines an
angular.jsonat/above the root,@angular/core/reactin any non-node_modulespackage.json, and source-file signatures, then prints one token and sets a matching exit code:reactorangular(exit 0) → use that framework. Do not ask the user — the detection is deterministic. Open<SKILL_DIR>/references/<framework>/localize.md.ambiguous(exit 2) → both frameworks are present. List<SKILL_DIR>/references/and ask the user which one to localize. If they name a framework with no matching reference folder, it is not supported here — stop.unknown(exit 3) → no supported framework detected. Terminate the workflow. Do not guess and do not proceed: report that neither React nor Angular signals were found in the bundle, so localization cannot continue, and stop here.
Throughout the steps below, <framework> means the folder chosen here. The deterministic
check scripts split by coupling:
- Framework-neutral, shared in
<SKILL_DIR>/scripts/—detect-framework.sh(the Step-0 detector above),check-org-api-version.shanddetect-bundle-type.sh(pure org/metadata checks), andcheck-manifest-registered.sh(agnostic skeleton; it takes--framework <framework>to select the call-site grammar). - Framework-specific, under
<SKILL_DIR>/references/<framework>/—check-i18n-wired.sh(its manifest-into-backend detection is i18n-library-shaped, so each framework ships its own).
Preconditions: verify before editing
| # | Requirement | Verify | If missing |
|---|---|---|---|
| 1 | It's a uiBundles/*/src/ project (React or Angular) |
Project structure matches | Not a UI Bundle → route to the correct skill |
| 2 | Platform SDK, UI Bundle, and build-plugin siblings installed and aligned (≥11.49.3) | package.json in the UI bundle dir |
Tell user to align and upgrade them; cannot proceed |
| 3 | You can identify where the app mounts | Read the entry file (see the framework reference) | No clear mount point → ask user to point it out |
| 4 | Target org actually supports API v68.0+ (runtime label GraphQL for UI Bundles ships in Release 264) | Run the runtime org-release check below | Org's max API version is below v68.0 (Release 262 or older) → cannot proceed; retarget a Release 264+ org or upgrade the org |
| 5 | The bundle is |
Установить experience-ui-bundle-localize в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл experience-ui-bundle-localize?
MUST activate to localize / internationalize a uiBundles/*/src/ project (React or Angular): extract hardcoded user-facing strings into Custom Labels, wire a runtime i18n library over the Platform SDK backend, add labels for another language, or troubleshoot label rendering across locales. Triggers: user-facing string literals in component files, a CustomLabels.labels-meta.xml, a src/i18n/ directory or label-manifest.ts, translation call sites, or requests to 'translate / localize / internationalize / support another language.' Scope: authenticated B2E UI Bundles and B2C site bundles. Use experience-ui-bundle-site-generate instead for site language configuration or sfdc_cms__languageSettings. DO NOT TRIGGER for B2B site bundles, building app shell/UI or styling, reading/writing/refreshing records (use experience-ui-bundle-salesforce-data-access), generating a new bundle (use experience-ui-bundle-frontend-generate), deploying (use experience-ui-bundle-deploy), or authoring translations in Translation Workbench.
Как установить скилл experience-ui-bundle-localize?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл experience-ui-bundle-localize запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic