Open TimothyGu opened 8 years ago
Proof of concept in https://github.com/pugjs/pug-lint/tree/eslint-formatter. Not all tests pass yet, but changing those is trivial.
Of course, that branch is not for merging, since it completely breaks the compatibility; but the core commit is 7b3443e6567c67f2ae125da66c6f62b1e4f1b125.
$ node bin/pug-lint -r eslint-formatter-pretty --config t.json a.pug
a.pug:1:1
× 1:1 ID literals must not be used disallowIdLiterals
1 error
$ node bin/pug-lint -r node_modules/eslint/lib/formatters/tap.js --config t.json a.pug
TAP version 13
1..1
not ok 1 - a.pug
---
message: ID literals must not be used
severity: error
data:
line: 1
column: 1
ruleId: disallowIdLiterals
...
What's the timeline for that commit being merged in? (And I guess therefore v3?)
This would have to go with v3, since it is an incompatible change.
Right, is there an estimated timeline for v3?
It would be cool to provide the same API as ESLint's formatters, so that we can reuse eslint's many formatters.