ShopperCove
Menu
All writingBlogTopicsCategoriesAboutRSS
Blog
Categories
Observability & SRE62All categories
About

Plate 16

  1. Blog

ESLint v10.12.0: SourceCode tokens/comments types + rule fixes (2 Oct 2026)

ESLint published v10.12.0 on 2 October 2026 as a minor release: documentation and TypeScript types for SourceCode#getText(), getLoc(), and getRange() now accept tokens and comments (matching runtime behavior), plus multiple rule fixes including astral/Unicode letter handling and autofix edge cases. npm latest confirmed 10.12.0; ShopperCove docs checklist only; no affiliate.

Aditya Challa·5 October 2026·4 min read

Summary
On this page
  1. SourceCode: tokens and comments in types/docs
  2. Rule fixes (edge cases, Unicode, autofix)
  3. Docs / chores (skim)
  4. Hands-on upgrade checklist
  5. Bottom line
  6. Sources
  7. Related

ESLint v10.12.0: SourceCode tokens/comments types + rule fixes (2 Oct 2026)

On 2 October 2026, ESLint published v10.12.0, a minor release that adds features and fixes bugs from the previous release. ShopperCove did not upgrade a production lint pipeline for this note and did not run benchmarks. Package identity was confirmed on the npm registry on 5 October 2026 (eslint@10.12.0, dist-tag latest). Primary source: the official ESLint v10.12.0 release blog. This is a docs-based upgrade checklist—not performance advice and not a security advisory (no CVEs are claimed here).

There is no affiliate link in this article. This post has no affiliate links.

SourceCode: tokens and comments in types/docs

Rule authors work with ESLint’s SourceCode object. Its getText(), getLoc(), and getRange() methods have long accepted a node, token, or comment at runtime, but documentation did not describe every argument type, and TypeScript definitions rejected some valid calls (for example, passing a comment).

v10.12.0 updates the documentation and type definitions to match actual behavior and to align with the core SourceCodeBase interface used in language plugins:

  • Existing call sites that already pass nodes/tokens/comments are unaffected at runtime.
  • TypeScript code that implements or mocks SourceCode may need getText / getLoc / getRange signatures updated to accept tokens and comments.

Feature commits called out in the blog: allow SourceCode#getText() to accept tokens and comments (#21340); handle astral letters in new-cap (#21357).

Rule fixes (edge cases, Unicode, autofix)

The blog lists rules updated for edge cases, including autofix behavior and supplementary Unicode / astral letter handling:

  • consistent-return
  • max-lines-per-function
  • new-cap
  • no-eval
  • no-invalid-this
  • no-loss-of-precision
  • prefer-arrow-callback
  • prefer-exponentiation-operator

Notable fix blurbs from the same release notes:

AreaWhat the notes say
prefer-arrow-callbackFalse positive in conditional test fixed
max-lines-per-functionSkip lines with multiple comments
Astral lettersFixes spanning consistent-return, no-eval, no-invalid-this (and new-cap feat)
prefer-exponentiation-operatorAutofix for async function base
curlyMissing space after else in autofix
id-lengthCorrect message for long private names
getFunctionHeadLocSupport TSFunctionType
no-loss-of-precisionFalse positive with 0.e5

Docs / chores (skim)

Documentation clarifications include one-var separateRequires matching any require() call, and a typo fix in no-unused-expressions. Chores include ecosystem plugin updates, CodeQL action bumps, Prettier dependency bumps, a perf change caching normalized config globals per languageOptions, and removal of CLAUDE.md in favor of AGENTS.md. Treat chores as release hygiene unless your fork tracked those files.

Hands-on upgrade checklist

  1. Inventory: npm ls eslint (or check the lockfile). Note whether you are below 10.12.0.
  2. Pin / bump in staging: install eslint@10.12.0 (or newer patch on the 10.12 line when available). Confirm with npm view eslint version → expect 10.12.0 as latest as of sources read 5 Oct 2026.
  3. TypeScript plugin / custom SourceCode mocks: if you implement SourceCode / SourceCodeBase, update getText / getLoc / getRange typings to accept tokens and comments.
  4. Re-run lint + autofix CI: especially suites that enable the rules listed above—watch for changed autofixes on prefer-exponentiation-operator, curly, and fewer false positives on prefer-arrow-callback / no-loss-of-precision.
  5. Unicode / identifiers: if you lint code with astral-plane identifiers, re-check new-cap and related rules after the bump.
  6. Do not invent security urgency: this minor is typed as features + bugfixes in the official blog; ShopperCove is not attaching CVE IDs.

ShopperCove did not change production ESLint versions for this article. Prefer the official release post over third-party roundups.

Bottom line

ESLint v10.12.0 (2 Oct 2026) is a practical minor: SourceCode docs/types finally match token/comment arguments, plus a batch of rule and autofix fixes (including astral letter handling). Pin eslint@10.12.0 when ready. No affiliate.

Sources

  • https://eslint.org/blog/2026/10/eslint-v10.12.0-released/
  • https://registry.npmjs.org/eslint/10.12.0
  • https://www.npmjs.com/package/eslint
  • https://github.com/eslint/eslint

Related

  • https://www.shoppercove.com/blog/vite-plus-1-0-unified-toolchain-october-2026
  • https://www.shoppercove.com/blog/playwright-1-63-test-locks-october-2026
  • https://www.shoppercove.com/blog/astro-7-3-preview-ignore-lock-october-2026
  • https://www.shoppercove.com/blog/angular-router-ssr-queryparams-dos-october-2026
  • https://www.shoppercove.com/blog/nodejs-26-lts-october-2026-schedule-change
  • https://www.shoppercove.com/blog/nextjs-15-lts-end-of-support-october-2026
  • https://www.shoppercove.com/blog/nextjs-16-3-8-security-release-2026
  • https://www.shoppercove.com/blog/firefox-157-security-fixes-css-changes-october-2026
eslintjavascripttypescriptsourcecodestatic analysislintingastral letters

Lab evidence

What I found running this

Sources read 5 Oct 2026 (Asia/Calcutta) via WebFetch/curl: official blog https://eslint.org/blog/2026/10/eslint-v10.12.0-released/ (Published 02 Oct 2026); npm registry eslint@10.12.0 (time 2026-10-02T20:08:19.213Z; dist-tag latest=10.12.0). Concrete upgrade checklist: pin eslint@10.12.0; review SourceCode mock/implement signatures if you implement SourceCodeBase (getText/getLoc/getRange now typed for tokens/comments); re-run autofix CI for rules listed—consistent-return, max-lines-per-function, new-cap, no-eval, no-invalid-this, no-loss-of-precision, prefer-arrow-callback, prefer-exponentiation-operator, plus curly space-after-else and id-length message fix. No production lint suite upgraded on ShopperCove; no invented CVEs. If CMS excerpt truncates, append this hands-on block.

Notes when a lab post goes up

Occasional email for new hands-on reviews. No sequence and no sponsors.

Related links

  • Plate 32

    Playwright 1.63: test locks, visible locators, richer traces (4 Sep 2026)

    Playwright 1.63.0 (4 Sep 2026) adds named test locks for shared resources, cross-frame frameLocator() without a selector, locator.visible(), richer step metadata, and optional aria/screen snapshots in traces. Experimental CT React/Vue packages freeze; Ubuntu 20.04 dropped. ShopperCove docs checklist only; no affiliate.

    5 Oct 2026

  • Plate 24

    SvelteKit 3 Is Here (Oct 1, 2026): Migration Checklist for Teams

    3 Oct 2026

  • Plate 46

    Remix 3 Ships Oct 2, 2026: What Frontend Teams Need to Know

    1 Oct 2026

On this page

  1. SourceCode: tokens and comments in types/docs
  2. Rule fixes (edge cases, Unicode, autofix)
  3. Docs / chores (skim)
  4. Hands-on upgrade checklist
  5. Bottom line
  6. Sources
  7. Related
All writingBlogCategoriesTopicsAboutPrivacyRSS

© 2026 ShopperCove