Daily Specs
Software & DevOps
Published on 2026-12-05Updated on 2026-12-05

Why Not Rewrite ESLint in Rust? Deep Architectural Analysis

Primary LanguageJavaScript (Node.js)
Alternative Rust ToolingOxlint, Biome, SWC
AST SpecificationESTree standard compliance
Plugin Ecosystem ModelDynamic JS-based runtime execution
Detailed technical specification diagram for Why not rewrite ESLint in Rust?

Key Takeaways

  • •ESLint's deeply embedded custom JavaScript plugin ecosystem makes a Rust rewrite architecturally impractical without breaking existing functionality.
  • •While tools like Biome and Oxlint demonstrate raw execution speed advantages using Rust, they operate on restricted subset rule sets.
  • •Dynamic runtime evaluation via Node.js AST traversals allows plugins to manipulate rules dynamically, a feature hard to mirror in statically compiled environments.
  • •The core maintainer team focuses on modernizing the existing codebase rather than pursuing a total rewrite from scratch.
Advertisement

Technical Specifications & Data

Primary LanguageJavaScript (Node.js)
Alternative Rust ToolingOxlint, Biome, SWC
AST SpecificationESTree standard compliance
Plugin Ecosystem ModelDynamic JS-based runtime execution
Type-Aware Linting SupportNative TypeScript Compiler API integration
Concurrency ModelSingle-threaded event loop (Node.js worker threads optional)
Ecosystem MaturityOver 10 years of community plugins and configurations
Performance ProfileModerate speed, highly extensible, large memory footprint
Migration FrictionExtremely high for complete drop-in replacement

Technical Architecture Overview

When examining the modern JavaScript tooling landscape, a prevailing trend has emerged: rewriting legacy build and lint tools in systems programming languages like Rust or Go. Projects such as SWC, Biome, and Oxlint have demonstrated staggering performance improvements over traditional JavaScript-based solutions. Consequently, developers frequently ask: Why not rewrite ESLint in Rust? The answer lies deep within ESLint's core architectural design, particularly how it handles abstract syntax trees (ASTs), runtime extensibility, and community plugins.

At its heart, ESLint is not merely a static code analyzer with a fixed set of rules; it is an extensible platform built on top of espree and custom parser options. The parser converts source code into an ESTree-compliant AST. ESLint then executes traversing routines where external plugins—often written by third-party developers—inject custom rules, visitor methods, and stateful transformations. This creates a highly dynamic runtime environment where JavaScript objects, closures, and callbacks are passed around freely during the linting phase.

Porting this to Rust would require either compiling a JavaScript runtime (like V8 or Boa) directly into the binary to execute custom plugins—which heavily negates the performance benefits of Rust—or enforcing that all plugins be rewritten as native Rust dynamic libraries (.so or .dll files). Requiring native compiled plugins would completely shatter the frictionless contribution model that has driven ESLint's massive ecosystem adoption over the past decade. Furthermore, AST representations in Rust (using enums and struct match statements) contrast sharply with the dynamic prototype-based property lookups utilized by JavaScript plugins, making a drop-in API equivalent nearly impossible to design without severe performance penalties and API friction.

Deep-Dive Systems & Performance Benchmarks

Performance benchmarks frequently favor Rust-based linters in cold-start scenarios and raw single-threaded throughput. Tools written in Rust can parse millions of lines of code in milliseconds by leveraging parallel iterators (via Rayon) and zero-copy string slicing. In contrast, Node.js-based linters face inherent overhead from garbage collection cycles, Just-In-Time (JIT) compilation warmup phases, and the single-threaded nature of the core event loop during synchronous AST traversals. However, raw execution speed is only one vector in a comprehensive developer experience metric.

Consider the complexity of the ruleset. ESLint supports thousands of rules, including complex type-aware rules that require integration with TypeScript's compiler API. A Rust-based rewrite would either need to reimplement a full TypeScript type checker from scratch—an immense undertaking that the TypeScript team itself continuously evolves—or interface with external compiler bindings, introducing inter-language communication overhead. "Speed without correctness and ecosystem compatibility is an empty victory," as many toolchain architects note. While Oxlint and Biome offer lightning-fast subset linting for standard formatting and basic syntax rules, they often fall short when executing complex, context-aware semantic rules that rely on project-wide type graphs.

Additionally, memory consumption patterns differ drastically. Node.js applications allocate significant heap memory for AST node objects, leading to higher baseline RAM usage during large monorepo builds. Rust applications manage memory deterministically through ownership and borrowing models, resulting in predictable, low-footprint memory profiles. Yet, the friction of maintaining dual ecosystems—where core linting happens in Rust but plugins remain in JavaScript—introduces serialization bottlenecks that can easily erase the performance gains achieved by native code execution.

Why This Matters & Industry Impact

The debate surrounding Why not rewrite ESLint in Rust? highlights a broader philosophical schism in modern software engineering: the tension between absolute performance optimization and ecosystem continuity. For enterprise organizations managing massive monorepos containing hundreds of thousands of files, linting speed directly impacts CI/CD pipeline costs and developer feedback loops. This is precisely why complementary tools like Oxlint exist—they step in to provide sub-second baseline checks, while ESLint remains the ultimate source of truth for complex, opinionated code quality rules.

Rather than abandoning a decade of stability and plugin development, the ESLint maintainer roadmap focuses on incremental performance optimization. By streamlining internal algorithms, reducing unnecessary object allocations, and leveraging modern Node.js performance enhancements (such as V8 updates and native modules where appropriate), ESLint continues to close the performance gap without forcing a destructive breaking change across the entire ecosystem. This pragmatic approach preserves backwards compatibility for millions of developers worldwide.

Ultimately, the industry benefits from this technological diversity. Rust-based linters push the boundaries of what is possible in terms of raw compute efficiency, forcing traditional JavaScript tool authors to optimize their engines. Meanwhile, JavaScript-based linters ensure that extensibility remains democratic, allowing any developer who knows JavaScript to write a custom rule in minutes without needing to understand systems programming concepts like lifetimes, unsafe blocks, or memory management. Understanding these trade-offs empowers engineering teams to choose the right tooling mix for their specific codebase scale and architectural requirements.

Accelerate your development workflow and secure your codebase with modern high-performance tooling combinations.

Chronological Timeline

2013

ESLint is created by Nicholas C. Zakas as a highly pluggable JavaScript linter.

2018-2020

Rise of Rust in web tooling begins with tools like SWC and esbuild prioritizing raw speed.

2023-2024

Rust-based linters like Biome and Oxlint gain massive traction in high-performance monorepos.

Present Day

Discussions on GitHub evaluate the architectural feasibility of rewriting ESLint, concluding that ecosystem extensibility makes a rewrite impractical.

Frequently Asked Questions

Is ESLint ever going to be rewritten in Rust?
No, core maintainers have noted that the architectural challenges, particularly maintaining the massive dynamic JavaScript plugin ecosystem, make a rewrite impractical.
What are the best Rust-based alternatives to ESLint?
Tools like Oxlint and Biome offer lightning-fast linting and formatting speeds by leveraging Rust, though they currently support subset rule sets compared to ESLint.
Why is plugin extensibility harder in Rust than in JavaScript?
JavaScript allows dynamic runtime evaluation and closures, whereas Rust requires static compilation, meaning plugins would either need to be compiled binary libraries or embed a JS runtime.
DS

Daily Specs Editorial Staff

Lead Technical Analyst & Hardware Researcher

Verified Expert

The Daily Specs editorial staff compiles, benchmarks, and verifies emerging technical specifications directly from system architecture manuals, hardware datasheets, and open-source codebases to deliver high-gain technical intelligence.

Advertisement

Related Technical Specs