DioxusLabs / DioxusLabs/docsite

Document when `prevent_default()` deviates from web expectations

Open
#497 1 comment 0 reactions 0 assignees View on GitHub
documentation enhancement
Dominant language
Rust
Stars
206
Forks
208
Avg merge
1h 11m
Merged PRs (30d)
3

Description

Just spent a while debugging a form submission issue because I was using `evt.prevent_default()` with a web mindset (the submit button will

This seems to have caused confusion for others in the past as well:
https://github.com/DioxusLabs/dioxus/issues/4045#issuecomment-2832226129
https://github.com/DioxusLabs/dioxus/issues/3904#issuecomment-2751486202
https://github.com/DioxusLabs/dioxus/issues/1297

I get that for cross-platform support the deviation makes sense, but since the Dioxus docs reference the MDN docs so much, I think it makes sense to have an explicit call-out for this.

I made the issue title focused on this specific deviation from expectations, but if there are other cases (web, desktop, or otherwise) it could make sense to have a page dedicated to framework design decisions that may conflict with preconceived notions from past experience. I'd imagine it would help with quicker acclimation for people coming from other frameworks.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.