New May 2, 2025

ESLint v9.26.0 released

Libraries, Frameworks, etc. All from ESLint Blog View ESLint v9.26.0 released on eslint.org

Highlights

MCP Server Integration

ESLint v9.26.0 adds support for a Model Context Protocol (MCP) server, enabling ESLint to interact with AI models and tools through a unified interface. This feature allows large language models (LLMs) to run ESLint in IDEs and other software, assisting developers with tasks like linting and code analysis. The MCP server can be started using the --mcp flag in the ESLint command line. This feature is particularly useful for developers using AI-powered coding assistants like GitHub Copilot. Read the documentation to learn how the MCP server can help you in your development tasks.

Support globalThis in no-shadow-restricted-names

The no-shadow-restricted-names rule now includes support for detecting shadowing of globalThis, in addition to other restricted identifiers like NaN, Infinity, undefined, eval, and arguments. To enable this feature, the reportGlobalThis option must be set to true.

/* eslint no-shadow-restricted-names: ["error", { "reportGlobalThis": true }] */

const globalThis = { /* custom object */ };

This enhancement helps developers avoid confusing or unintended shadowing of the globalThis object, which was introduced in the ECMAScript 2020 language specification.

ignoreDirectives option in no-unused-expressions

The no-unused-expressions has a new ignoreDirectives option which can be used to ignore directives in ES3 codebases. This option allows users to ignore directives (e.g., "use strict") when linting ES3 codebases. By default, the rule now reports directives as unused expressions in ES3 environments, as ES3 does not formally support directives, treating them as unused code. This behavior aligns with the default behavior in ESLint v9.25.0, which was reverted in ESLint v9.25.1 because of compatibility concerns.

Features

Bug Fixes

Documentation

Chores

Scroll to top