Cargo.toml 1.3 K · 39 lines · raw · history

1 [package]
2 name = "simulator"
3 version = "0.1.0"
4 edition = "2024"
5
6 [dependencies]
7 bevy = { version = "0.20.0", features = ["serialize"] }
8 serde = { version = "1", features = ["derive"] }
9 serde_json = "1"
10
11 [target.'cfg(target_arch = "wasm32")'.dependencies]
12 web-sys = { version = "0.3", features = ["Window", "Storage"] }
13
14 # Enable a small amount of optimization in the dev profile.
15 [profile.dev]
16 opt-level = 1
17
18 # Enable a large amount of optimization in the dev profile for dependencies.
19 [profile.dev.package."*"]
20 opt-level = 3
21
22 # Enable more optimization in the release profile at the cost of compile time.
23 [profile.release]
24 # Compile the entire crate as one unit.
25 # Slows compile times, marginal improvements.
26 codegen-units = 1
27 # Do a second optimization pass over the entire program, including dependencies.
28 # Slows compile times, marginal improvements.
29 lto = "thin"
30
31 # Optimize for size in the wasm-release profile to reduce load times and bandwidth usage on web.
32 [profile.wasm-release]
33 # Default to release profile values.
34 inherits = "release"
35 # Optimize with size in mind (also try "z", sometimes it is better).
36 # Slightly slows compile times, great improvements to file size and runtime performance.
37 opt-level = "s"
38 # Strip all debugging information from the binary to slightly reduce file size.
39 strip = "debuginfo"