We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6937e52 commit 96eaeaaCopy full SHA for 96eaeaa
src/rule.ts
@@ -222,15 +222,15 @@ export const codegen: eslint.Rule.RuleModule = {
222
message += hunk.lines.join('\n')
223
const startPosition = position(range[0])
224
225
+ const fix: Parameters<typeof context.report>[0]['fix'] = fixer => fixer.replaceTextRange(range, normalise(result.right) + os.EOL)
226
context.report({
227
message,
228
loc: {
229
start: {line: startPosition.line + hunk.oldStart, column: 0},
230
end: {line: startPosition.line + hunk.oldLines, column: 0},
231
},
- // suggest: [
232
- // {fix: fixer => fixer.replaceTextRange()}
233
- // ]
+ fix,
+ // todo: fix or suggest based on an option
234
})
235
}
236
0 commit comments