
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
i18n-placeholder-checker
Advanced tools
CLI and programmatic utility to ensure locale JSON files keep the same placeholders as a source language (default zh-cn.json).
# install locally
npm install --save-dev i18n-placeholder-checker
# run the CLI (defaults shown)
npx i18n-placeholder-checker \
--source zh-cn.json \
--cwd .
| Flag | Description |
|---|---|
-s, --source <file> | Source locale file used as the placeholder reference. Defaults to zh-cn.json. |
--cwd <path> | Directory containing locale files. Defaults to the current working directory. |
--ignore <file> | Additional JSON files to skip. Repeat the flag or provide a comma-separated list. |
The CLI exits with code 1 when placeholder mismatches are detected so it fits into Git hooks and CI jobs.
import { checkPlaceholders, renderReport } from "i18n-placeholder-checker";
const report = await checkPlaceholders({
cwd: process.cwd(),
source: "zh-cn.json",
ignore: ["package.json"],
});
renderReport(report);
if (!report.ok) {
process.exit(1);
}
report contains:
ok: true when no placeholder mismatches exist.failures: array of files with placeholder errors plus warnings.warningsOnly: files that only have skipped keys/non-string issues.version in package.json.npm run lint:placeholders).npm login) if needed.npm publish --access public.Note: the consumer project references this package via a local
file:dependency until an official version is published to npm.
FAQs
Validate locale placeholder parity against a source JSON file.
We found that i18n-placeholder-checker demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.