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

xilem_web: Should helper functions for known attributes be added to elements? #462

Open
casey opened this issue Jul 28, 2024 · 1 comment
Labels

Comments

@casey
Copy link
Contributor

casey commented Jul 28, 2024

I noticed that HtmlButtonElement has a disabled helper method for setting the disabled state, but that, for example, HtmlIFrameElement doesn't have a src helper method for setting the <iframe> src attribute. Is it desired to have such helper methods? If so, I'd be happy to submit a PR.

@Philipp-M
Copy link
Contributor

Yeah that's actually the plan, and I'm happy for PRs implementing this, e.g. the HtmlImageElement does have src already, currently just wrapping Attr is fine. Ideally this should access the DOM attributes directly of the underlying element, but I have concerns regarding the resulting binary size with the code that's necessary for this (which is why there's a commented out feature gate above those traits).

github-merge-queue bot pushed a commit that referenced this issue Jul 31, 2024
Apropos of #462. Let me know if this should have a test or an example!
@flosse flosse added the web label Aug 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants