Skip to content

Editorial: Eliminate w-nodev & w-dev nested within w-nodev #11265

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

Merged
merged 2 commits into from
Apr 29, 2025

Conversation

jmdyck
Copy link
Contributor

@jmdyck jmdyck commented Apr 28, 2025

(Presented as 2 commits for possible ease of review. Squash on merge, I expect.)

Within an element marked w-nodev:

  • It's redundant to have an inner element marked w-nodev, so delete the tags of the inner element, retaining its content.
  • It's pointless to have an inner element marked w-dev, so delete the whole inner element.

Running html-build confirms no change to the output, other than deleting some blank lines.


/iframe-embed-object.html ( diff )
/interactive-elements.html ( diff )

jmdyck added 2 commits April 27, 2025 22:14
It's redundant to have an element marked `w-nodev`
within another element marked `w-nodev`.
Delete the tags of the inner element, keeping its content.
It's pointless to have an element marked `w-dev`
within an element marked `w-nodev`.
Delete the inner element, including its content.
@zcorpan
Copy link
Member

zcorpan commented Apr 28, 2025

These are for https://html.spec.whatwg.org/dev/

@jmdyck
Copy link
Contributor Author

jmdyck commented Apr 29, 2025

Not sure what you mean by "these". I understand that w-dev and w-nodev generally determine what does and doesn't go into the "Edition for Web Developers". What I'm saying is that these particular occurrences of those attributes don't in fact make any difference to what goes in the dev edition (or any other edition).

I probably should have been clearer in the last para of my original comment:
A default run of html-build (generating the single-page, multi-page, and dev editions) confirms that these commits cause no change to the output, other than deleting some blank lines.

@zcorpan
Copy link
Member

zcorpan commented Apr 29, 2025

I see, apologies for not looking more carefully.

Running document.querySelectorAll('[w-nodev] [w-nodev]') in devtools when loading source gives 15 elements, and '[w-nodev] [w-dev]' 2 elements, which matches the removed elements here.

@zcorpan zcorpan merged commit 0b136bd into whatwg:main Apr 29, 2025
2 checks passed
@jmdyck jmdyck deleted the nested_w branch April 29, 2025 18:08
@tabatkins
Copy link
Contributor

It would probably be a good idea, if possible, to also lint against this happening in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

3 participants