Skip to main content
shipi18n logo|Documentation

empty-value: empty translation values

error — fails the build

The source string has content but the translation is an empty string. The key "exists", so key-set diffing passes it — and the user sees nothing at all where text should be.

What triggers it

// en.json
{ "welcome": "Welcome back!" }

// ja.json
{ "welcome": "" }

Fixed

// ja.json
{ "welcome": "おかえりなさい!" }

Why it matters

Empty values are how "we'll fill this in later" becomes production UI with blank buttons. They are strictly worse than missing keys, because most i18n libraries fall back on a missing key but happily render an empty one.

How to fix it

Provide the translation, or delete the key so your library falls back to the source language.

How to silence it

--ignore-keys for keys that are intentionally empty in some locales.

Check for this in CI

npx @shipi18n/cli check ./locales -s en
# SARIF for inline PR annotations:
npx @shipi18n/cli check ./locales -s en -r sarif -o shipi18n.sarif

The structural checks need no API key. Findings of this rule link back to this page from the SARIF helpUri.

Related rules