bevy/tools/example-showcase/src
François e944b0a3a5
Optimize wasm examples for the website (#8636)
# Objective

- Improve speed of loading examples on the website
- Triggered by https://news.ycombinator.com/item?id=35996393

## Solution

- Use wasm-opt to optimize files for size. This reduces the files from
22mb to 13mb
- Cloudflare doesn't set the correct `Content-Type` header by default
for wasm files, add it manually. This enables wasm streaming and
compression, dropping the transfer to 3.9mb

The files with this script are deployed on
optimized.wasm-pages.pages.dev if you want to test, you can replace this
URL on a website deployed locally.
2023-05-19 17:57:54 +00:00
..
main.rs Optimize wasm examples for the website (#8636) 2023-05-19 17:57:54 +00:00