-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
#[cfg(feature = "render")]
and yew::Renderer
#2498
Conversation
Visit the preview URL for this PR (updated for commit a3efdb2): https://yew-rs--pr2498-feat-render-lo1tccs5.web.app (expires Sat, 26 Mar 2022 00:32:20 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 |
# Conflicts: # examples/function_router/Cargo.toml # examples/function_router/index.html # examples/function_router/src/main.rs # packages/yew/Cargo.toml
# Conflicts: # packages/yew/src/app_handle.rs # packages/yew/src/dom_bundle/bcomp.rs # packages/yew/src/html/component/scope.rs # packages/yew/src/lib.rs # packages/yew/src/virtual_dom/vcomp.rs
Just requesting my own review so I don't forget to look at this |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Implementation looks good. Just a few comments
Size Comparison
|
The measured drop in size for |
function_router has feature render disabled by default because it's also used in ssr by the upcoming ssr_router example. |
I suspected as much. Then this is a perfect example of the benefit of having |
I will merge this pull request as I believe all items has been addressed. |
Description
Originally part of #2453.
yew::Renderer
that supersedesstart_app_*
.render
allowing client-side rendering logic to be disabled for server-side rendering.This pull request also includes changes from the following pull requests to avoid repeatedly resolving conflicts:
Caveats
This pull request inevitably introduces a lot of feature flags into the codebase.
However, I don't have a better way to handle this at the moment.
Checklist
cargo make pr-flow