# What Programming Languages Does Automattic Harper Use? A Code-Level Breakdown

> Discover the programming languages Automattic Harper uses, from Rust in its core engine to JavaScript and TypeScript for its interfaces and plugins. Get a code-level breakdown.

- Repository: [Automattic/harper](https://github.com/Automattic/harper)
- Tags: deep-dive
- Published: 2026-07-27

---

**Automattic Harper is built primarily in Rust for its core grammar-checking engine, with JavaScript and TypeScript powering the web interfaces, browser extensions, VS Code plugin, and Tauri desktop application.**

Automattic Harper is an open-source grammar checker whose repository is organized as a multi-language workspace. If you are investigating what programming languages Automattic Harper uses, the answer centers on a robust Rust foundation paired with an extensive JavaScript and TypeScript ecosystem for user-facing tools. The architecture deliberately isolates performance-critical text analysis in Rust crates while delegating UI and integration logic to TypeScript frontends.

## Rust Powers the Core Engine and CLI

The heart of Harper lives in Rust. According to the Automattic/harper source code, the workspace defines multiple crates—including `harper-core`, `harper-ls`, `harper-cli`, and `harper-wasm`—each anchored by a [`Cargo.toml`](https://github.com/Automattic/harper/blob/main/Cargo.toml) file.

Key entry points include:

- [`harper-core/Cargo.toml`](https://github.com/Automattic/harper/blob/main/harper-core/Cargo.toml) — the root grammar engine crate.
- [`harper-ls/src/main.rs`](https://github.com/Automattic/harper/blob/main/harper-ls/src/main.rs) — the language server binary.
- [`harper-cli/src/main.rs`](https://github.com/Automattic/harper/blob/main/harper-cli/src/main.rs) — the command-line interface.
- [`harper-wasm/src/lib.rs`](https://github.com/Automattic/harper/blob/main/harper-wasm/src/lib.rs) — the WebAssembly bridge.

You can install and run the CLI directly from the Rust source:

```bash

# Install the CLI (built from the Rust crate harper-cli)

cargo install --path harper-cli

# Lint a markdown file

harper-cli lint path/to/file.md

```

## JavaScript and TypeScript Drive the UI and Extensions

All external-facing components rely on JavaScript or TypeScript. The documentation site is built with **SvelteKit**, browser extensions—including `harper-chrome-plugin` and `harper-firefox-plugin`—and the VS Code plugin are bundled with Vite, and the desktop client uses Tauri’s Rust backend with a Svelte/TypeScript frontend. Key files range from [`harper-chrome-plugin/src/manifest.json`](https://github.com/Automattic/harper/blob/main/harper-chrome-plugin/src/manifest.json) to [`harper-vscode-plugin/src/extension.ts`](https://github.com/Automattic/harper/blob/main/harper-vscode-plugin/src/extension.ts).

### WebAssembly and Node.js Integration

The `harper-wasm` crate compiles the Rust core to WebAssembly, exposing it through the [`harper.js`](https://github.com/Automattic/harper/blob/main/harper.js) wrapper. This lets Node.js and browser clients call the grammar engine without managing a native binary:

```ts
import { Linter } from "harper.js";

async function lintText(text: string) {
  const linter = await Linter.create();         // loads the WASM module (Rust)
  const results = await linter.lint(text);      // returns lint diagnostics
  console.log(results);
}

lintText("# Hello world\nThis is a test.");

```

### VS Code Extension

The VS Code plugin is implemented in TypeScript. It interacts with the linter via a client abstraction defined in the desktop package:

```ts
import * as vscode from "vscode";
import { Client } from "harper-desktop/src/lib/client";

export function activate(context: vscode.ExtensionContext) {
  const client = new Client();
  vscode.workspace.onDidChangeTextDocument(async (e) => {
    const diagnostics = await client.getDiagnostics(e.document.getText());
    // Populate VS Code diagnostics...
  });
}

```

### Desktop Application and Documentation Site

The Tauri-based desktop app (`harper-desktop`) combines a Rust backend—declared in [`harper-desktop/src-tauri/Cargo.toml`](https://github.com/Automattic/harper/blob/main/harper-desktop/src-tauri/Cargo.toml)—with a frontend defined in files such as [`harper-desktop/src/lib/client.ts`](https://github.com/Automattic/harper/blob/main/harper-desktop/src/lib/client.ts). Meanwhile, the documentation site is a SvelteKit TypeScript project; content pages such as `packages/web/src/routes/docs/about/+page.md` render Harper’s web presence.

## Summary

- **Rust** is the primary language for Harper’s core grammar engine, CLI (`harper-cli`), language server (`harper-ls`), and WebAssembly bridge (`harper-wasm`).
- **JavaScript and TypeScript** power all user-facing integrations, including the VS Code extension, browser extensions, SvelteKit documentation site, and Tauri desktop frontend.
- The project follows a clear architectural boundary: Rust handles performance-critical linting, while TypeScript manages UI and IDE bindings.

## Frequently Asked Questions

### Is Automattic Harper written entirely in Rust?

No. While the grammar engine, language server, CLI, and WebAssembly bridge are written in Rust, significant portions of the project are implemented in JavaScript and TypeScript. The VS Code extension, browser plugins, documentation site, and Tauri desktop frontend are all built with TypeScript.

### What framework does Harper use for its web documentation?

Harper uses **SvelteKit**, a TypeScript-based framework, for its web documentation site and demo. Source content is authored in Markdown and served from paths such as `packages/web/src/routes/docs/about/+page.md`.

### Can I use Harper in a JavaScript or TypeScript project?

Yes. The `harper-wasm` crate compiles the Rust core to WebAssembly, which is distributed through the [`harper.js`](https://github.com/Automattic/harper/blob/main/harper.js) package. You can instantiate a `Linter`, load the WASM module asynchronously, and lint strings directly in Node.js or the browser.

### What is the desktop client built with?

The desktop client is a **Tauri** application. It uses Rust for the backend process and Svelte with TypeScript for the frontend UI layer. Key files include [`harper-desktop/src-tauri/Cargo.toml`](https://github.com/Automattic/harper/blob/main/harper-desktop/src-tauri/Cargo.toml) for the Rust side and [`harper-desktop/src/lib/client.ts`](https://github.com/Automattic/harper/blob/main/harper-desktop/src/lib/client.ts) for the frontend client logic.