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

popup-info-box-web-component violates HTML spec #34

Open
arcticmatt opened this issue May 15, 2021 · 1 comment
Open

popup-info-box-web-component violates HTML spec #34

arcticmatt opened this issue May 15, 2021 · 1 comment
Labels
bug Indicates an unexpected problem or unintended behavior. Content: WebAPI help wanted If you know something about this, we would love your help!

Comments

@arcticmatt
Copy link

The spec says this:

The element's attributes and children must not be inspected, as in the non-upgrade case none will be present, and relying on upgrades makes the element less usable.

The popup-info-box-web-component example violates this! See https://github.com/mdn/web-components-examples/blob/master/popup-info-box-web-component/main.js#L22

The example still works because the script is loaded with defer. However, it doesn't work if you do something like this:

const elem = document.createElement('popup-info');
elem.setAttribute("data-text", "foo");
document.body.appendChild(elem);

Since this example is so visible, it would be nice if it followed the spec.

@Rumyra Rumyra added bug Indicates an unexpected problem or unintended behavior. Content: WebAPI time: -3hr help wanted If you know something about this, we would love your help! labels May 6, 2022
@Rumyra
Copy link
Contributor

Rumyra commented May 6, 2022

Related #33

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior. Content: WebAPI help wanted If you know something about this, we would love your help!
Projects
None yet
Development

No branches or pull requests

3 participants