-
-
Notifications
You must be signed in to change notification settings - Fork 114
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
Feat: Add pre-rendering and persistent rendering modes. #501
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
andycall
force-pushed
the
feat/offline_rendering
branch
from
October 13, 2023 09:44
d7fbefc
to
3969f1e
Compare
andycall
force-pushed
the
feat/pre_load
branch
from
October 19, 2023 06:58
dcc86a4
to
a3848db
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
October 19, 2023 06:59
ddc36cd
to
4931156
Compare
andycall
force-pushed
the
feat/pre_load
branch
from
October 25, 2023 14:01
a3848db
to
1d88eda
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
November 16, 2023 12:31
4155ad9
to
e174113
Compare
andycall
changed the title
[WIP]: Feat: Add pre-rendering and persistent rendering modes.
Feat: Add pre-rendering and persistent rendering modes.
Nov 20, 2023
andycall
force-pushed
the
feat/offline_rendering
branch
2 times, most recently
from
December 4, 2023 04:02
c081663
to
3e3939c
Compare
andycall
changed the base branch from
main
to
feat/feat/dedicated_js_thread_v2
December 4, 2023 04:03
andycall
force-pushed
the
feat/offline_rendering
branch
from
December 4, 2023 08:43
3e3939c
to
7075989
Compare
andycall
force-pushed
the
feat/feat/dedicated_js_thread_v2
branch
2 times, most recently
from
December 27, 2023 08:35
3db0328
to
4dbfca3
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
December 27, 2023 12:34
5e2dcdc
to
3b62da4
Compare
andycall
force-pushed
the
feat/feat/dedicated_js_thread_v2
branch
from
December 28, 2023 07:52
1ecfb58
to
79dc274
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
December 28, 2023 10:04
d1be344
to
f419ecd
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
January 4, 2024 14:28
d782406
to
f04d7d3
Compare
andycall
force-pushed
the
feat/offline_rendering
branch
from
January 17, 2024 11:31
7552f93
to
c2bde64
Compare
looseyi
approved these changes
Jan 17, 2024
Ivan-young66
approved these changes
Jan 17, 2024
andycall
force-pushed
the
feat/offline_rendering
branch
from
January 18, 2024 12:12
6ac077a
to
62d3079
Compare
fix: fix prerendering didn't exec external scripts created by scripts.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds two load modes, allowing developers to preload and prerender web pages before these pages are mounted into the Flutter tree.
<style>
and<link>
elements will be parsed and the calculated styles applied to the corresponding DOM elements. However, JavaScript code will not be executed in this mode. If the entrypoint is a JavaScript file, WebF only do loading until the WebF widget is mounted into the Flutter tree. Using this mode can save up to 50% of loading time, while maintaining a high level of compatibility with the standard mode. It's safe and recommended to use this mode for all types of pages.aggressive
mode is a step further thanpreloading
, cutting down up to 90% of loading time for optimal performance. This mode simulates the instantaneous response of native Flutter pages but may require modifications in the existing web codes for compatibility. In this mode, all remote resources are loaded and executed similarly to the standard mode, but with an offline-like behavior. Given that JavaScript is executed in this mode, properties likeclientWidth
andclientHeight
from the viewModule always return 0. This is because no layout or paint processes occur during preRendering. If your application depends on viewModule properties, ensure that the related code is placed within theload
andDOMContentLoaded
event callbacks of the window. These callbacks are triggered once the WebF widget is mounted into the Flutter tree. Apps optimized for this mode remain compatible with bothstandard
andpreloading
modes.