Internationalization Rules

VerifiedSafe

Provides rules for internationalizing multi-language websites: using localized fields in CMS, managing translatable labels in Astro components, and formatting dates, numbers, currencies, and lists with native Intl APIs. Useful for any locale-aware code or when adding text to Astro components without hardcoding strings.

Sby Skills Guide Bot
DevelopmentIntermediate
6/2/2026
Claude CodeCursorWindsurfCopilot
#internationalization#localization#i18n#astro#cms

Recommended for

Automated summary

Provides rules for handling internationalization in a multi-language website, including CMS localized fields, translation management via global labels, and JavaScript Intl API formatting for dates, lists, and currencies.

Strengths

  • Avoids hardcoding text strings, promotes use of native Intl APIs, organizes translations in a central CMS global, ensures locale-aware formatting.

Limitations

  • Assumes a specific CMS structure (labels global), requires discipline to keep labels in sync, may not cover complex pluralization or RTL languages in depth.
When to use it

Use when building or maintaining a multi-language Astro website with CMS-driven translations and locale-aware formatting.

When not to use it

Not suitable for single-language sites or projects using a dedicated i18n library like react-i18next.

Security analysis

Safe
Quality score90/100

The skill provides coding guidelines for internationalization; it does not instruct any executable commands, network operations, or data exfiltration. There is no risk of harm.

No concerns found

How this analysis is made

Examples

Add a localized label for a new button
I'm adding a new button to the homepage. Generate the CMS label entry and usage in an Astro component following our i18n rules.
Format a date in the user's locale
I need to display a publication date in French and English. Show me how to use Intl.DateTimeFormat with the active locale from global state.
Display a list of authors with locale-aware separator
I have an array of author names. How should I format them as a localized list using Intl.ListFormat?

name: intl description: Internationalization rules for multi-language websites. Use when working on localized text fields in the CMS, Intl formatting (dates, numbers, currencies, lists) in Astro components, or any locale-aware code.

Internationalization Rules

CMS: Localized Fields

  • All text fields (e.g. labels, titles) should have localized: true

Web: Labels & Translations

This is a multi-language website. When adding labels or text to Astro components:

  1. Never hardcode text strings - All user-facing text must be translatable
  2. Update the CMS labels global - Add necessary fields to /cms/src/globals/labels.ts
    • Use the global group for common, site-wide labels (e.g., "show-more", "close", "loading")
    • Use specific groups for scoped labels (e.g., articles for article-related text, contact for contact forms)
  3. Access labels in components - Use const { labels } = globalState
  4. Example usage: labels.articles['written-by'] or labels.global['show-more']
  • When adding labels to the CMS, ensure you use all of them. Delete unused labels after implementation.

Web: Formatting with Intl APIs

Use the built-in JavaScript Intl APIs for locale-aware formatting. Never use third-party libraries or manual string concatenation.

The active locale must come from the global state (const { locale } = globalState). Never hardcode a locale string.

Date & Time

const formatDate = (date: Date | string) =>
  new Intl.DateTimeFormat(locale, {
    day: '2-digit',
    month: 'long',
    year: 'numeric',
  }).format(new Date(date));

Lists

const formatList = (items: string[], type: Intl.ListFormatType = 'conjunction') =>
  new Intl.ListFormat(locale, { type }).format(items);

Currency & Numbers

const formatCurrency = (value: number, currency = 'EUR') =>
  new Intl.NumberFormat(locale, {
    style: 'currency',
    currency,
    minimumFractionDigits: 2,
  }).format(value);

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/internationalization-rules-mmio70g3/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/internationalization-rules-mmio70g3' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/internationalization-rules-mmio70g3/download' --output '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md.part' && mv '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md.part' '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md' && test -s '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/intl' && cp -R '.skill-downloads/internationalization-rules-mmio70g3' '.claude/skills/intl'

Cursor
test -f '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md' && test -s '.skill-downloads/internationalization-rules-mmio70g3/SKILL.md' && mkdir -p '.cursor/skills' && test ! -e '.cursor/skills/intl' && cp -R '.skill-downloads/internationalization-rules-mmio70g3' '.cursor/skills/intl'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/internationalization-rules-mmio70g3'

openskills read 'internationalization-rules-mmio70g3'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/internationalization-rules-mmio70g3/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills