Skip to content
Skillpedia
Websites & UI (frontend)75k · #2981

pluralization

What it does

This skill reviews how a site shows counts such as 'you have 3 items' and updates the code so plurals are correct for each language. It is for developers building multilingual apps.

When to use it

  • ✓When you ask the agent to check how counts and plurals are written in your app's translations.
  • ✓When translated text reads oddly because the plural form is wrong for a language.
  • ✓When you set up an internationalization library and want plural selection handled correctly.

Skill link

https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/pluralization/SKILL.md

Copy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.

How to use

The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.

Ready-to-paste message

Use this skill to help me: https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/pluralization/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
Want your AI to find skills like this on its own?Install the free Skillpedia MCP: one line, and it searches 15,000+ skills before each task.Install in 1 minute →

Example of what to ask your AI

“My app shows counts like '1 items' in some languages. Can you fix how plurals are handled for all my languages?”

5 new skills a week. 1 minute to read.

How it works

The agent finds places where a count is joined to text with plus signs or only checks singular and plural. It replaces them with Intl.PluralRules or ICU message syntax so the right form is picked for each language.

Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

Handle plural forms with Intl.PluralRules or ICU MessageFormat

Pluralization rules vary dramatically across languages — what works as a simple singular/plural branch in English produces grammatically wrong output in Arabic, Russian, Polish, and dozens of other languages. Shipping incorrect plurals signals low translation quality and breaks trust with native speakers in target markets.

Quick Reference

  • English has 2 plural forms but Arabic has 6 and Russian has 3
  • Never concatenate a count with a string like '"You have " + count + " items"'
  • Use Intl.PluralRules to select the right message key per locale
  • ICU MessageFormat in react-intl or i18next handles plural selection automatically

Check

Find all places in this codebase where a count value is concatenated with a string or where only singular/plural branching is used, without Intl.PluralRules or ICU plural syntax.

Fix

Replace count string concatenation and binary singular/plural logic with Intl.PluralRules-based key selection or ICU MessageFormat plural syntax so that all CLDR plural categories are covered for every target locale.

Explain

Explain why languages have different numbers of plural forms, what CLDR plural categories are, and how Intl.PluralRules and ICU MessageFormat solve pluralization correctly across locales.

Code Review

Review translation files and components that render counts. Flag any strings that concatenate a number with text, any ternary that picks only between "singular" and "plural", and any i18next or react-intl message that is missing plural keys required by the target locale.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/i18n/pluralization

FAQ

Why is one singular and one plural form not enough?

The skill says languages differ a lot, and English has two plural forms while Arabic has six and Russian has three.

What is Intl.PluralRules?

It is a built-in browser feature that picks the correct plural category for a number in a given language.

Does this work with popular libraries?

The skill mentions ICU MessageFormat in libraries such as react-intl and i18next, which handle plural selection.

Details

Original description by the author

Use when reviewing string concatenation involving counts, translation key lookups, or i18n library configurations to check whether plural forms are handled correctly for all target locales.

repo: thedaviddias/Front-End-Checklist

Popularity

GitHub stars
75k
Ranking position
#2981
License
MIT
Updated
10/31/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills