From 4499b5c313d30a3189a58fdd74fc4ed4b2428afd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20=C4=8C=C3=AD=C5=BEek?= Date: Mon, 22 Nov 2021 09:08:15 +0100 Subject: [PATCH] Update docs. See #396. --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 500f0c5c..21fba128 100644 --- a/README.md +++ b/README.md @@ -162,6 +162,8 @@ The filter property determines whether or not an element should be replaced with * `filter: 'p'` will select `

` elements * `filter: ['em', 'i']` will select `` or `` elements +The tag names in the `filter` property are expected in lowercase, regardless of their form in the document. + Alternatively, the filter can be a function that returns a boolean depending on whether a given node should be replaced. The function is passed a DOM node as well as the `TurndownService` options. For example, the following rule selects `` elements (with an `href`) when the `linkStyle` option is `inlined`: ```js