npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

lexa-cli

v0.1.0

Published

Command-line client for Lexa, a translation management system. Sync translation files, inspect progress, and script localization workflows.

Readme

lexa-cli

Command-line client for Lexa, a translation management system. Sync translation files between your repository and Lexa, inspect progress, and script localization workflows in CI.

Zero runtime dependencies. Requires Node 18+ (uses native fetch).

Install

npm install -g lexa-cli

Or run without installing:

npx lexa-cli status --project my-app

Authenticate

Create an API key in Lexa under Settings → API Keys, then:

lexa login --url https://lexa.example.com --key sk-...

The key is verified before being saved, so a typo fails immediately rather than on your next command. Credentials are written to ~/.lexa/credentials.json with 0600 permissions.

In CI, skip login and set environment variables instead — they take precedence over the stored file, so nothing is written to disk:

export LEXA_URL=https://lexa.example.com
export LEXA_API_KEY=sk-...

Key scopes: pull, status, projects, and languages work with a read-only key. push requires a read/write key.

Set up a repository

lexa init --project my-app

This writes a .lexarc recording the project, its languages, and an output directory. It contains no secrets and is safe to commit — teammates then run lexa pull with no flags.

{
  "project": "my-app",
  "languages": ["fr", "de"],
  "out": "./locales"
}

Sync translations

Pull approved translations into local files:

lexa pull                          # every language in .lexarc
lexa pull --lang fr                # one language
lexa pull --nested                 # nested JSON for i18next/ngx-translate
lexa pull --all-states             # include unapproved drafts

By default pull writes only approved translations, matching what Lexa's own export produces — so the files you commit are publishable. Keys are sorted, giving stable diffs across pulls.

Push local edits back:

lexa push --lang fr --dry-run      # preview what would change
lexa push --lang fr

push only updates values for keys that already exist in the project, and only those whose value actually differs. Keys not present in Lexa are reported and skipped rather than created — importing new terms is a deliberate operation that belongs in the web UI or your repo sync, not a side effect of pushing a file.

Inspect

lexa projects                      # projects visible to this key
lexa languages --project my-app    # configured languages and coverage
lexa status --project my-app       # approval progress per language
lexa whoami                        # check stored credentials still work
$ lexa status --project my-app
My App (my-app)
  fr        84% approved  (412/490 approved, 470 translated)
  de       100% approved  (490/490 approved, 490 translated)

Use in CI

Every command exits non-zero on failure, so failures stop a pipeline. To fail a build when translations drift from what's committed:

lexa pull --lang fr --out ./locales
git diff --exit-code ./locales

Reference

| Command | Purpose | | --- | --- | | login --url <url> --key <key> | Verify and store credentials | | whoami | Check stored credentials | | init --project <ref> [--out <dir>] | Write .lexarc | | projects | List accessible projects | | languages [--project <ref>] | List languages with coverage | | status [--project <ref>] | Approval progress per language | | pull [--lang <code>] [--out <dir>] [--nested] [--all-states] | Write translations to files | | push --lang <code> [--file <path>] [--dry-run] | Upload translation values |

Projects can be referenced by slug, name, or UUID. --project overrides .lexarc.

| Environment variable | Purpose | | --- | --- | | LEXA_URL | API base URL (overrides stored config) | | LEXA_API_KEY | API key (overrides stored config) | | LEXA_CONFIG_DIR | Override ~/.lexa |