-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Fix MDN URLs in api folder #5203
Conversation
Hey @bershanskiy, thanks for taking initiative on this one! I agree, this is a big problem that we should have resolved. A couple of things, though:
|
Do you mean split the data changes into a separate PR?
I'm not sure it's possible to make a script to update these files because there are too many edge cases. E.g., when to use slash and when to use
This is true. I started with API data just to try out the method. I agree: the whole data should be linted, ideally.
Ooops... Good catch! Another thing I noticed is: many |
Ack, forgot to say "data" -- that's what I mean, yeah!
Hmm, yeah, you do have a point... This makes me wonder if we should have a bulk update process for changes that are better to be performed manually, rather than by a script -- maybe we should just keep it broken up into small PR chunks?
This is a really good point, and one we should look into more. Overall, I feel that this boils down to localization, which is an ongoing discussion in #114. |
@vinyldarkscratch Let's split this PR into multiple. I dropped non-data changes to focus this commit on |
FYI, all changes are basically one-liners. Some files have large diffs because the change is in the dictionary key and after sorting the order of features changes so diffs look rather large. |
Thanks for splitting it up! Yeah, this looks great, and we should be able to review it pretty soon. We should also take the description from this and apply it to a PR that contains the linter script (don't worry if it fails without the data changes; that just shows it's working), and write up a new description -- one that doesn't have the "fixes" keyword. Can we do that? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, just got a couple out-of-scope changes we should probably separate into its own PR!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for all of your hard work on this, this is looking good to me!
Summary
Fix MDN URLs in
api
folder.Currently,
mdn_url
s are full of mischief like linkingMagnetometer.x
toMagnetometer.y
. :)This linter finds all URLs that don't match either of two patterns:
There are still a few non-standard URLs, which I think should just be whitelisted individually. (Details below.)
CSSMathNegate.values
was renamed intoCSSMathNegate.value
because that is the standard name.Headers.headers
renamed toHeaders.Headers
because it is a constructor.MediaKeyStatusMap.iterator
renamed toMediaKeyStatusMap.@@iterator
to match existing naming convention.Related
#5201 is a tracking bug for all MDN URLs.
#5195 was the original issue that demonstrated existence of incorrect URLs.
A checklist to help your pull request get merged faster: