-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[wasm] Introduce <InvariantTimezone> build flag #87284
Conversation
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsIn Net8 we bundle the timezone database into .wasm file by default. It's not separate download anymore. To to make download size of wasm/wasi application smaller, we could link it out. In the project file
Requires re-linking with wasm workload. Also backward compatible with Fixes #37973 for wasm
|
Is it the right time to have two WASM flavors/files in the runtime pack and choose between them during client app build? |
I don't have bandwidth to implement it. |
756d84c
to
cda65db
Compare
/azp run runtime-wasm |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run runtime-wasm |
Azure Pipelines successfully started running 1 pipeline(s). |
# Conflicts: # src/mono/sample/wasm/browser-advanced/Wasm.Advanced.Sample.csproj
/azp run runtime-wasm-optional |
Azure Pipelines successfully started running 1 pipeline(s). |
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.
Looks good to me 👍
How big is the size savings from this? Just curious |
|
||
Author: [Pavel Savara](https://github.com/pavelsavara) | ||
|
||
It's currently only available for Browser OS |
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.
Maybe specifically call out that it strips the tz data from the binary
...nuget/Microsoft.NET.Sdk.WebAssembly.Pack/build/Microsoft.NET.Sdk.WebAssembly.Browser.targets
Show resolved
Hide resolved
over 200KB |
# Conflicts: # src/mono/wasm/build/WasmApp.targets
In Net8 we bundle the timezone database into .wasm file by default. It's not separate download anymore.
To to make download size of browser/wasi application smaller, we could link it out.
The runtime would behave as if there was no timezones in the database and use UTC.
For WASI, it doesn't try to load it from host FS unless you also set
TZDIR
env variable.In the project file
Requires re-linking with wasm workload.
Also backward compatible with
BlazorEnableTimeZoneSupport
but with workload.Fixes #37973 for wasm