Skip to content
Permalink
Browse files

Chore: Fix linting issues

  • Loading branch information...
molant authored and antross committed Mar 26, 2019
1 parent f37d646 commit 6b9e20e0d2736b3306978fd4f313cade006e157e
Showing with 6 additions and 2 deletions.
  1. +6 −2 packages/hint/docs/contributor-guide/how-to/formatter.md
@@ -4,11 +4,13 @@ A `formatter` formats the results of `webhint`: from crafting `JSON` to
connecting to a database and storing the results in it.

To create one, you will need a class that implements the interface
`IFormatter`. This inteface has a method `format` witch will receive an
array of `message`s if any issues have been found.
`IFormatter`. This inteface has an `async` method `format` that
receives an array of `message`s if any issues have been found.

The following is a basic `formatter` that `.stringify()`s the results:

<!-- eslint-disable require-await -->

```js
export default class JSONFormatter implements IFormatter {
public async format(messages: Problem[], options: FormatterOptions = {}) {
@@ -33,6 +35,8 @@ With this, you can group the issues by `resource` and sort them by
`line` and `column`. Using the previous example and `lodash` will
look as follows:

<!-- eslint-disable require-await -->

```js
import * as _ from 'lodash';

0 comments on commit 6b9e20e

Please sign in to comment.
You can’t perform that action at this time.