[Docs] Update jsx-no-target-blank.md#3818
Draft
brunocoelho wants to merge 1 commit intojsx-eslint:masterfrom
Draft
[Docs] Update jsx-no-target-blank.md#3818brunocoelho wants to merge 1 commit intojsx-eslint:masterfrom
brunocoelho wants to merge 1 commit intojsx-eslint:masterfrom
Conversation
* Add missing ponctuation. * Rewrite a couple of sentences.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #3818 +/- ##
==========================================
- Coverage 97.77% 97.63% -0.14%
==========================================
Files 135 135
Lines 9741 9741
Branches 3558 3558
==========================================
- Hits 9524 9511 -13
- Misses 217 230 +13 ☔ View full report in Codecov by Sentry. |
ljharb
requested changes
Sep 11, 2024
|
|
||
| When creating a JSX element that has an `a` tag, it is often desired to have the link open in a new tab using the `target='_blank'` attribute. Using this attribute unaccompanied by `rel='noreferrer'`, however, is a severe security vulnerability (see [noreferrer docs](https://html.spec.whatwg.org/multipage/links.html#link-type-noreferrer) and [noopener docs](https://html.spec.whatwg.org/multipage/links.html#link-type-noopener) for more details) | ||
| This rules requires that you accompany `target='_blank'` attributes with `rel='noreferrer'`. | ||
| When creating a JSX element with an `a` tag, the link is often desired to open in a new tab using the `target='_blank'` attribute. Using this attribute unaccompanied by `rel='noreferrer'`, however, is a severe security vulnerability (see [noreferrer docs](https://html.spec.whatwg.org/multipage/links.html#link-type-noreferrer) and [noopener docs](https://html.spec.whatwg.org/multipage/links.html#link-type-noopener) for more details). |
Member
There was a problem hiding this comment.
"the link is often desired to open" reads wrong to me; the "it" isn't referring to "the link" but to "a generic person"
| ## When Not To Use It | ||
|
|
||
| If you do not have any external links or forms, you can disable this rule. | ||
| You can disable this rule if you do not have any external links or forms. |
Member
There was a problem hiding this comment.
"If x, you can disable this rule" is the form we most typically use in all the rule docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.