Skip to content

Commit 4007247

Browse files
committed
Update jsx-no-blank doc after review
1 parent da8c6b2 commit 4007247

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

docs/rules/jsx-no-target-blank.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ This rule aims to prevent user generated links from creating security vulnerabil
2020

2121
* enabled: for enabling the rule. 0=off, 1=warn, 2=error. Defaults to 0.
2222
* enforce: optional string, 'always' or 'never'
23-
* Link components can be something other than an `<a>`, see [shared settings](https://github.com/yannickcr/eslint-plugin-react/blob/master/README.md#configuration) for `linkComponents` configuration)
2423

2524
### `enforceDynamicLinks`
2625

@@ -55,9 +54,9 @@ When {"enforceDynamicLinks": "never"} is set, the following patterns are **not**
5554
var Hello = <a target='_blank' href={dynamicLink}></a>
5655
```
5756

58-
### Link components
57+
### Custom link components
5958

60-
Link components can be something other than an `<a>`, see [shared settings](https://github.com/yannickcr/eslint-plugin-react/blob/master/README.md#configuration) for `linkComponents` configuration)
59+
This rule supports the ability to use custom components for links, such as `<Link />` which is popular in libraries like `react-router`, `next.js` and `gatsby`. To enable this, define your custom link components in the global [shared settings](https://github.com/yannickcr/eslint-plugin-react/blob/master/README.md#configuration) under the `linkComponents` configuration area. Once configured, this rule will check those components as if they were `<a />` elements.
6160

6261
The following patterns are considered errors:
6362

0 commit comments

Comments
 (0)