Installation

Gukhanmun ships two JavaScript implementations that share the same API:

PackageEnvironmentsNotes
@gukhanmun/wasmBrowsers, Node.js 20+, Deno 2.0+, Bun 1.0+Recommended for broad compatibility
@gukhanmun/napiNode.js 20+, Deno 2.0+, Bun 1.0+Faster on server; native code

For most projects, use @gukhanmun/wasm. Switch to @gukhanmun/napi for server workloads where throughput matters.

WebAssembly

For most environments, the WebAssembly implementation is the best choice. It runs in browsers, Node.js, Deno, and Bun, and does not require native code. Install it with your package manager of choice:

npm
yarn
pnpm
bun
deno
npm add @gukhanmun/wasm

Node-API

For Node.js, Deno, or Bun with the native addon:

npm
yarn
pnpm
bun
deno
npm add @gukhanmun/napi

Standard Korean Dictionary

The JavaScript packages do not bundle the Standard Korean Dictionary. Install it separately:

npm
yarn
pnpm
bun
deno
npm add @gukhanmun/stdict-fst
npm
yarn
pnpm
bun
deno
npm add @gukhanmun/stdict-cdb

Both packages contain the same dictionary; the formats differ in their lookup characteristics. For most use cases, prefer the FST package.

NAPI platform binaries

@gukhanmun/napi includes prebuilt binaries for:

  • macOS: ARM64, x86_64
  • Windows: ARM64, x86_64
  • Linux (glibc): ARM64, x86_64

Alpine Linux (musl) requires building from source.