Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[New] jsx-no-target-blank: add fixer #2862

Merged
merged 1 commit into from Jan 8, 2021

Conversation

@Nokel81
Copy link
Contributor

@Nokel81 Nokel81 commented Nov 25, 2020

No description provided.

lib/rules/jsx-no-target-blank.js Show resolved Hide resolved
lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
Copy link
Collaborator

@ljharb ljharb left a comment

Almost there :-)

lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
tests/lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
tests/lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
tests/lib/rules/jsx-no-target-blank.js Outdated Show resolved Hide resolved
errors: defaultErrors
}, {
code: '<a target={"_blank"} href={"//example.com"} rel={"noopenernoreferrernoreferrernoreferrernoreferrernoreferrer"}></a>',
output: '<a target={"_blank"} href={"//example.com"} rel={"noopener noreferrer"}></a>',

This comment has been minimized.

@ljharb

ljharb Dec 23, 2020
Collaborator

it's fine to keep it here since the original was both a string and had curly braces

@ljharb ljharb changed the title add fixer for the jsx-no-target-blank rule [New] jsx-no-target-blank: add fixer Dec 23, 2020
@Nokel81 Nokel81 requested a review from ljharb Dec 23, 2020
@ljharb ljharb force-pushed the Nokel81:add-fixer-no-target-blank branch from de33e0b to 907c8e8 Dec 29, 2020
@ljharb
ljharb approved these changes Dec 29, 2020
@ljharb ljharb force-pushed the Nokel81:add-fixer-no-target-blank branch from 907c8e8 to 11eaaae Dec 30, 2020
@ljharb
Copy link
Collaborator

@ljharb ljharb commented Dec 30, 2020

@Nokel81 ok! i think this time i've got it down to 4 failures, not just in older eslint versions: namely, that the fixer is fixing the code in the spread attribute case. If CI ends up showing those same 4 failures, then fixing that would be the last step to landing this.

@ljharb
Copy link
Collaborator

@ljharb ljharb commented Dec 30, 2020

Please mark the PR as ready for review once either the tests are passing or you're stuck again (hopefully the former :-p )

@ljharb ljharb marked this pull request as draft Dec 30, 2020
@Nokel81 Nokel81 force-pushed the Nokel81:add-fixer-no-target-blank branch 2 times, most recently from b914d29 to 26a9307 Jan 7, 2021
@Nokel81 Nokel81 marked this pull request as ready for review Jan 7, 2021
@Nokel81
Copy link
Contributor Author

@Nokel81 Nokel81 commented Jan 7, 2021

@ljharb All tests are passing.

@ljharb
ljharb approved these changes Jan 8, 2021
@ljharb ljharb force-pushed the Nokel81:add-fixer-no-target-blank branch from 26a9307 to 4f2d1eb Jan 8, 2021
@ljharb ljharb merged commit 4f2d1eb into yannickcr:master Jan 8, 2021
43 checks passed
43 checks passed
@github-actions
Automatic Rebase
Details
@github-actions
Require “Allow Edits”
Details
@github-actions
matrix
Details
@github-actions
pretest
Details
@github-actions
readme
Details
@github-actions
latest majors (15, 7)
Details
@github-actions
posttest
Details
@github-actions
latest majors (15, 6)
Details
@github-actions
latest majors (15, 5)
Details
@github-actions
latest majors (15, 4)
Details
@github-actions
latest majors (14, 7)
Details
@github-actions
latest majors (14, 6)
Details
@github-actions
latest majors (14, 5)
Details
@github-actions
latest majors (14, 4)
Details
@github-actions
latest majors (13, 7)
Details
@github-actions
latest majors (13, 6)
Details
@github-actions
latest majors (13, 5)
Details
@github-actions
latest majors (13, 4)
Details
@github-actions
latest majors (12, 7)
Details
@github-actions
latest majors (12, 6)
Details
@github-actions
latest majors (12, 5)
Details
@github-actions
latest majors (12, 4)
Details
@github-actions
latest majors (11, 7)
Details
@github-actions
latest majors (11, 6)
Details
@github-actions
latest majors (11, 5)
Details
@github-actions
latest majors (11, 4)
Details
@github-actions
latest majors (10, 7)
Details
@github-actions
latest majors (10, 6)
Details
@github-actions
latest majors (10, 5)
Details
@github-actions
latest majors (10, 4)
Details
@github-actions
latest majors (9, 6)
Details
@github-actions
latest majors (9, 5)
Details
@github-actions
latest majors (9, 4)
Details
@github-actions
latest majors (8, 6)
Details
@github-actions
latest majors (8, 5)
Details
@github-actions
latest majors (8, 4)
Details
@github-actions
latest majors (7, 5)
Details
@github-actions
latest majors (7, 4)
Details
@github-actions
latest majors (6, 5)
Details
@github-actions
latest majors (6, 4)
Details
@github-actions
latest majors (5, 4)
Details
@github-actions
latest majors (4, 4)
Details
@github-actions
node 4+
Details
@Nokel81 Nokel81 deleted the Nokel81:add-fixer-no-target-blank branch Jan 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants