ampproject / ampproject/amp-toolbox
Linter: don't duplicate warning message
- Dominant language
- HTML
- Stars
- 459
- Forks
- 242
- PR merge metrics
- No merged PRs in 30d
Description
Currently, the same warning message is repeated for each error:
```
[I] ~/P/a/p/linter (master↑1|✚11) $ amp lint https://amp.dev
PASS 1x1 images are specified by
WARN All have reasonable width and height
> [https://blog.amp.dev/wp-content/uploads/2019/06/cf_hero.png]: actual ratio [1999/1140 = 1.75] does not match specified [16/9 = 1.77]
WARN All have reasonable width and height
> [https://blog.amp.dev/wp-content/uploads/2018/10/img_20180926_163001-01.jpeg]: actual ratio [3680/2314 = 1.59] does not match specified [16/9 = 1.77]
```
It'd be better to show it only once for each error:
```
[I] ~/P/a/p/linter (master↑1|✚11) $ amp lint https://amp.dev
PASS 1x1 images are specified by
WARN All have reasonable width and height
> [https://blog.amp.dev/wp-content/uploads/2019/06/cf_hero.png]: actual ratio [1999/1140 = 1.75] does not match specified [16/9 = 1.77]
> [https://blog.amp.dev/wp-content/uploads/2018/10/img_20180926_163001-01.jpeg]: actual ratio [3680/2314 = 1.59] does not match specified [16/9 = 1.77]
```
Contributor guide
Assessment
This issue has not been assessed yet.