From 57b0370383a3ddbb439beed6313c36eadb5a6f7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Sajn=C3=B3g?= Date: Sun, 5 Nov 2017 19:10:36 +0100 Subject: [PATCH 1/2] Update html-end-tags doc --- docs/rules/html-end-tags.md | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/docs/rules/html-end-tags.md b/docs/rules/html-end-tags.md index 51acebeda..f10867871 100644 --- a/docs/rules/html-end-tags.md +++ b/docs/rules/html-end-tags.md @@ -2,17 +2,12 @@ - :wrench: The `--fix` option on the [command line](http://eslint.org/docs/user-guide/command-line-interface#fix) can automatically fix some of the problems reported by this rule. -This rule enforce the way of end tags. - -- [Void elements] disallow end tags. -- Other elements require end tags. - ## :book: Rule Details -This rule reports the following elements: +This rule reports: -- [Void elements] which have end tags. -- Other elements which do not have end tags and are not self-closing. +- presence of end tags on [Void elements](https://www.w3.org/TR/html51/syntax.html#void-elements) +- absence of end tags or self-closed endings on other elements :-1: Examples of **incorrect** code for this rule: @@ -46,9 +41,3 @@ This rule reports the following elements: ## :wrench: Options Nothing. - -[Void elements]: https://www.w3.org/TR/html51/syntax.html#void-elements - -## TODO: `

` - -`parse5` does not recognize the illegal end tags of void elements. From bba116d97825fc4436c9997e0281c6b8d589d3a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Sajn=C3=B3g?= Date: Thu, 16 Nov 2017 00:47:03 +0100 Subject: [PATCH 2/2] Improve wording --- docs/rules/html-end-tags.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/rules/html-end-tags.md b/docs/rules/html-end-tags.md index f10867871..c0df4f541 100644 --- a/docs/rules/html-end-tags.md +++ b/docs/rules/html-end-tags.md @@ -6,8 +6,8 @@ This rule reports: -- presence of end tags on [Void elements](https://www.w3.org/TR/html51/syntax.html#void-elements) -- absence of end tags or self-closed endings on other elements +- presence of and end tag on [Void elements](https://www.w3.org/TR/html51/syntax.html#void-elements) +- absence of both an end tag (e.g. ``) and a self-closing opening tag (e.g. `
`) on other elements :-1: Examples of **incorrect** code for this rule: