Skip to content

Commit 2a85e9d

Browse files
committed
Pre-compress and embed assets in release mode
1 parent 9162fc8 commit 2a85e9d

File tree

6 files changed

+236
-88
lines changed

6 files changed

+236
-88
lines changed

Cargo.lock

+156-57
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ thiserror = "1"
2626
tracing = { version = "0.1" }
2727
tokio = { version = "1.33.0", features = ["full"] }
2828
tower = { version = "0.4.13", features = ["full"] }
29-
tower-http = { version = "0.5", features = ["full"] }
29+
tower-http = { version = "0.5", features = ["fs", "compression-gzip", "compression-br"] }
3030
uuid = { version = "1.9.0", features = [
3131
"v4",
3232
"serde",
@@ -53,7 +53,7 @@ lib-package = "frontend"
5353

5454
# The site root folder is where cargo-leptos generate all output. WARNING: all content of this folder will be erased on a rebuild. Use it in your server setup.
5555
site-root = "target/site"
56-
hash-files = false
56+
hash-files = true
5757

5858
# The site-root relative folder where all compiled output (JS, WASM and CSS) is written
5959
# Defaults to pkg

app/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ fn Dashboard() -> impl IntoView {
114114

115115
use qbittorrent_rs_sse::sse_sync_maindata;
116116
// Create sse signal
117-
let data = sse_sync_maindata("http://localhost:3010/sse");
117+
let data = sse_sync_maindata("/sse");
118118

119119
view! {
120120
<div>Count: {move || { view! { <div>

0 commit comments

Comments
 (0)