CARVIEW |
Select Language
HTTP/2 200
date: Wed, 23 Jul 2025 06:19:03 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
etag: W/"847ebc688efa4a05aeb6d48a59d9426c"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=6Z%2FmPVXSTj1aZZ8mQLqYmRgPaWXO1ttEGPB4mMiX6pWribXe3KsKHzrZTah0oUVXT8dfJ%2B650Ut07PTduoYjwK53puJvHlhRSzKFov2NXcfOYODx9zZFCgNkwyXVwK%2BuPspVey8Jj%2Ff6uxU%2FutPdSgx68UksMtWrq6xCja0n%2FgAKuxleGoAJ67m%2Fa8qvWyPvYdqX9XUWGyqnjKZ5k7Hq6onxs%2BIAN2xYfVKkGn6FeVN04HYZ%2BBJjSJxiSqN9gGqlxI368qw8IhIAjrQgVi0wLw%3D%3D--0XhGk6R%2F8v4lrISN--hpY1LWvcPSOM5RuOx29NSQ%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.1609030447.1753251542; Path=/; Domain=github.com; Expires=Thu, 23 Jul 2026 06:19:02 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Thu, 23 Jul 2026 06:19:02 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: A448:3B93B0:4FAC82:6731CC:68807ED6
Release v12.2.0 · textlint/textlint · GitHub
Loading
Skip to content
Navigation Menu
{{ message }}
-
-
Notifications
You must be signed in to change notification settings - Fork 156
v12.2.0
Compare
12.2.0 (2022-06-25)
Features
Implement Improve error location RFC #835
It will make the error location more details.
This change is for rule developer.
- Add
loc
andrange
property toTextlintMessage
(result) - Add
padding
prorperty toRuleError(message, details)
. - Add
locator
object to rule's contextlcoator.at(index)
,locator.range([startIndex, endIndex])
, andlocator.loc({ start: { line, column }, end: { line, column }})
.
- textlint-tester's
valid
andinvalid
supportrange
property - Deprecate
index
,line
andcolumn
property onTextlintMessage
andreport
function- Preserve current behavior for backward compatible
- Update
filterMessages
to use newrange
property onTextlintMessage
- Use
readonly [number, number]
as range in all packages - Fix
filterMessages
bug c8a670f - Refactor tests
- Update rule.md documentation
- Add
padding
andlocator
object - Add
peerDependencies
note
- Add
textlint v12.2.0 will introduce padding
and locator
.
If your will use it, please add peerDependencies
to package.json
on your rule package.
- Edit: No more peerDependencies. It is complex and there are less advantages.
"peerDependencies": {
"textlint": ">= 12.2.0"
},
"peerDependenciesMeta": {
"textlint": {
"optional": true
}
}
For textlint rule creator
Before:
const { Syntax, report, RuleError } = context;
// .....
report(node, new RuleError(message, {
index: 1
}));
After:
const { Syntax, report, RuleError, locator } = context;
// .....
report(node, new RuleError(message, {
padding: locator.at(1)
}));
If you want to get more correct location, please use locator.range
or locator.loc
const { Syntax, report, RuleError, locator } = context;
// .....
report(node, new RuleError(message, {
padding: locator.range([1, 5]) // The error related to 1 - 5 index.
}));
For more details, see https://textlint.github.io/docs/rule.html#ruleerror
Changelogs
Bug Fixes
- deps: update babel monorepo (89b2395)
- deps: update babel monorepo (6a3e841)
- deps: update babel monorepo (a91e594)
- deps: update babel monorepo (c9f1957)
- deps: update babel monorepo to ^7.16.5 (#834) (dcbc196)
- deps: update babel monorepo to ^7.16.7 (e8c10aa)
- deps: update babel monorepo to ^7.17.10 (1539f0a)
- deps: Update chalk (#842) (56ba52c)
- deps: update dependency @babel/core to ^7.17.12 (add5313)
- deps: update dependency @babel/core to ^7.17.9 (db74d3a)
- deps: update dependency @babel/core to ^7.18.2 (73c2047)
- deps: update dependency table to ^6.7.5 (fdfcce6)
- deps: update dependency table to ^6.8.0 (5e1aa18)
- deps: Update packages that depend on ansi-regex (#841) (17c03cd)
- deps: Update string-width (#844) (675bc93)
- textlint: remove log-symbols (#845) (000d07a)
Features
Assets 2
You can’t perform that action at this time.