-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCargo.toml
62 lines (55 loc) · 1.46 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
[package]
name = "leptos_wasmcloud"
version = "0.1.0"
edition = "2021"
[lib]
crate-type = ["cdylib"]
[dependencies]
bytes = "1.7.2"
cfg-if = "1"
console_error_panic_hook = "0.1.7"
futures = "0.3.30"
wasi = { version = "0.13.1", optional = true }
hydration_context = { git = "https://github.com/leptos-rs/leptos" }
leptos = { git = "https://github.com/leptos-rs/leptos" }
leptos_meta = { git = "https://github.com/leptos-rs/leptos" }
leptos_router = { git = "https://github.com/leptos-rs/leptos" }
leptos_wasi = { git = "https://github.com/leptos-rs/leptos_wasi", optional = true }
wasm-bindgen = { version = "0.2.95", optional = true }
[features]
hydrate = [
"leptos/hydrate",
"dep:wasm-bindgen",
]
ssr = [
"leptos/ssr",
"leptos_meta/ssr",
"leptos_router/ssr",
"dep:leptos_wasi",
"dep:wasi",
]
[profile.wasm-release]
inherits = "release"
opt-level = 'z'
lto = true
codegen-units = 1
panic = "abort"
[package.metadata.leptos]
tailwind-input-file = "styles/tailwind.css"
# == Hydrate (client)
lib-profile-release = "wasm-release"
lib-features = ["hydrate"]
lib-cargo-args = [
"-Zbuild-std=std,panic_abort,core,alloc",
"-Zbuild-std-features=panic_immediate_abort",
]
# == SSR
bin-profile-release = "wasm-release"
bin-target-triple = "wasm32-wasip2"
bin-features = ["ssr"]
bin-cargo-command = "cargo-component"
bin-target-dir = "target/server"
bin-cargo-args = [
"-Zbuild-std=std,panic_abort,core,alloc",
"-Zbuild-std-features=panic_immediate_abort,wasi_ext",
]