-
Notifications
You must be signed in to change notification settings - Fork 22.4k
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
Example code has the condition reversed #34111
Labels
Comments
emrys57
added
the
needs triage
Triage needed by staff and/or partners. Automatically applied when an issue is opened.
label
Jun 13, 2024
Josh-Cena
added
good first issue
A good issue for newcomers to get started with.
and removed
needs triage
Triage needed by staff and/or partners. Automatically applied when an issue is opened.
labels
Jun 13, 2024
Josh-Cena
changed the title
Example javascript on MDN seems wrong
Example code has the condition reversed
Jun 13, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
MDN URL
https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/currentSrc
What specific section or headline is this issue about?
The example section javascript code
What information was incorrect, unhelpful, or incomplete?
This seems to write "Using the 200px image." if the
currentSrc
does not end with "200px".What did you expect to see?
"Using the 400px image!"
Open the clock image on a new tab. It has the 400px URL. Yet the text says 200px.
This behaviour occurs in Firefox and Chrome.
Do you have any supporting links, references, or citations?
No response
Do you have anything more you want to share?
No response
MDN metadata
Page report details
en-us/web/api/htmlimageelement/currentsrc
The text was updated successfully, but these errors were encountered: