Add a "fix message" to every autofix-able check (#1489)

This commit is contained in:
Charlie Marsh 2022-12-30 23:16:03 -05:00 committed by GitHub
parent 1e3cf87f67
commit 01c74e0629
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
25 changed files with 594 additions and 166 deletions

View file

@ -56,7 +56,9 @@ export default function SourceEditor({
.filter((check) => position.startLineNumber === check.location.row)
.filter((check) => check.fix)
.map((check) => ({
title: `Fix ${check.code}`,
title: check.fix
? check.fix.message ?? `Fix ${check.code}`
: "Autofix",
id: `fix-${check.code}`,
kind: "quickfix",
edit: check.fix