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

fixnow

v2.0.5

Published

Tiny multilingual spell checker with suggestions. Arabic, German, English, Spanish, French, Portuguese, Russian and Vietnamese dictionaries bundled — one install, zero runtime dependencies.

Readme

A tiny multilingual spell checker with correction suggestions. Dictionaries are bundled, so npm i fixnow gives you everything — with zero runtime dependencies, in both ESM and CommonJS.

Features

  • 📦 Zero Dependencies — Keeps your node_modules clean and lightweight.
  • 🌍 Built-in Dictionaries — Includes Arabic, German, English, Spanish, French, Portuguese, Russian, and Vietnamese.
  • Slim Builds — Import only the language you need (e.g. import { check } from "fixnow/es") to optimize bundle size.
  • 🛡️ Smart Tokenization — Automatically ignores code spans, URLs, emails, and identifiers to prevent false positives.
  • 🧩 Universal — Works seamlessly in both ESM and CommonJS projects.

Architecture

flowchart LR
    Input["Input Text"] --> Tokenizer
    Tokenizer --> |"Skips Code / URLs"| Check{"Dictionary"}
    Check -->|"Valid Word"| Pass["No Issues"]
    Check -->|"Typo Detected"| Engine("Correction Engine")
    Engine --> Issues["SpellIssue[]"]

    style Input fill:#18181b,stroke:#ef4444,stroke-width:2px,color:#fff
    style Issues fill:#18181b,stroke:#ef4444,stroke-width:2px,color:#fff

Install

npm i fixnow

Languages

| Code | Language | Dictionary license | | ---- | ---------- | ------------------ | | ar | Arabic | LGPL-3.0 | | de | German | LGPL-3.0 | | en | English | MIT | | es | Spanish | LGPL-3.0 | | fr | French | MIT | | pt | Portuguese | GPL-3.0-or-later | | ru | Russian | GPL-3.0-or-later | | vi | Vietnamese | MIT |

Usage

import { checkText, suggest, createChecker } from "fixnow";

// English
const enIssues = await checkText("This sentance has a typo", {
  language: "en",
  suggestions: true,
});
// -> [{ offset: 5, length: 8, word: 'sentance', suggestions: [...] }]

// Spanish — opt in to accent leniency if you don't want "codigo" flagged.
const esIssues = await checkText("Esto es un herror", {
  language: "es",
  suggestions: true,
  acceptAccentOmissions: true,
});
// -> [{ offset: 11, length: 6, word: 'herror', suggestions: [...] }]

// One-off correction suggestions
await suggest("bonjoor", { language: "fr" }); // -> ['bonjour', ...]

// A checker bound to one language
const de = createChecker("de");
await de.isCorrect("Haus"); // -> true

CommonJS works too:

const { checkText } = require("fixnow");

API

  • checkText(text, options)Promise<SpellIssue[]>
  • isCorrect(word, language, options?)Promise<boolean>
  • suggest(word, { language, max? })Promise<string[]>
  • createChecker(language) → bound { check, suggest, isCorrect, warmup }
  • warmup(language?) — preload dictionaries (skip first-call decode cost)
  • tokenize(text, protectedSegments?), DEFAULT_PROTECTED_PATTERN
  • SUPPORTED_LANGUAGES, LANGUAGES, isSupportedLanguage

CheckOptions: language (required), caseSensitive (false), acceptAccentOmissions (false; Spanish only), suggestions, maxSuggestions (5), minWordLength (3), ignoreWords, flagWords, isProtectedWord, protectedSegments.

Tokenization

checkText skips anything inside a "protected segment" (code spans, URLs, emails, paths, CLI flags, hex colors, ACRONYMS, file names and dotted identifiers). Override the patterns with protectedSegments:

import { checkText, DEFAULT_PROTECTED_PATTERN } from "fixnow";

// Use only your own pattern
await checkText(text, { language: "en", protectedSegments: /\{\{[^}]+\}\}/g });

// Compose with the default
await checkText(text, {
  language: "en",
  protectedSegments: [DEFAULT_PROTECTED_PATTERN, /\{\{[^}]+\}\}/g],
});

// Disable protection entirely
await checkText(text, { language: "en", protectedSegments: false });

The same option is exposed on tokenize(text, protectedSegments).

Slim Builds

If you only need one language, import it via the language subpath. Your bundler only copies the dictionary you actually use:

import { check, suggest } from "fixnow/es";

const issues = await check("Esto es un herror", { suggestions: true });
await suggest("bonjoor", 3); // bound suggest is (word, max?)

The slim entries (fixnow/ar, fixnow/de, fixnow/en, fixnow/es, fixnow/fr, fixnow/pt, fixnow/ru, fixnow/vi) re-export a checker pre-bound to that language.

Bundling

fixnow reads its dictionaries from disk at runtime — they ship as files under node_modules/fixnow/dictionaries/, not as inlined bytes in the JS. So any bundler must treat fixnow as external, leaving it to load from node_modules at runtime. This is required for VS Code extensions and any CJS bundle: inlining fixnow into a CJS output strips the path anchor it uses to find its dictionaries, and it will throw a clear "mark 'fixnow' as external" error instead of resolving them.

// esbuild
await esbuild.build({
  entryPoints: ["src/extension.ts"],
  bundle: true,
  format: "cjs",
  platform: "node",
  external: ["fixnow"],
});

The matching option for other bundlers:

  • Vitebuild.rollupOptions.external: ['fixnow']
  • Rollupexternal: ['fixnow']
  • webpackexternals: { fixnow: 'commonjs fixnow' }

Migrating from 1.x

2.0.0 cleans up three rough edges from the extraction-from-F1 release. Each is a breaking change:

  • language is now required. There is no default language anymore.
    // before
    await checkText("hola"); // implicitly Spanish
    // after
    await checkText("hola", { language: "es" });
  • strict is split into caseSensitive and acceptAccentOmissions. The new default is strict (the old strict: true). If you relied on strict: false to tolerate Spanish accent omissions, opt in explicitly:
    // before
    await checkText("codigo", { language: "es" }); // accepted
    // after
    await checkText("codigo", { language: "es", acceptAccentOmissions: true });
    The legacy strict key still works in 2.x with a console.warn; it is removed in 3.0.0.
  • F1-specific markers are gone from the default tokenizer. [Image #1], [Skills #…], /skills #N, and /skill no longer auto-skip. If you need them, pass them via protectedSegments:
    const F1_MARKERS =
      /\[(?:Image|Code|Text) #\d+[^\]\n]*\]|\[Skills? #[^\]\n]+\]|\/skills #\d+|\/skill\b/g;
    await checkText(text, {
      language: "en",
      protectedSegments: [DEFAULT_PROTECTED_PATTERN, F1_MARKERS],
    });

License

MIT