Skip to content

Commit

Permalink
⬆️ Bump wasm-bindgen.
Browse files Browse the repository at this point in the history
  • Loading branch information
langyo committed Oct 10, 2024
1 parent 741c113 commit 08c353f
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ web-sys = { version = "^0.3", features = [
"WheelEvent",
] }
js-sys = "^0.3"
wasm-bindgen = "0.2.92"
wasm-bindgen = "0.2.94"
wasm-bindgen-futures = "^0.4"
gloo = "^0.11"

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apt update && apt install -y clang
RUN rustup target add wasm32-unknown-unknown
RUN rustup target add wasm32-wasi
RUN cargo install cargo-make
RUN cargo install [email protected].92
RUN cargo install [email protected].94

COPY ./Cargo.toml /home/Cargo.toml
RUN cargo new --name server /home/packages/server
Expand Down
29 changes: 16 additions & 13 deletions packages/types/src/consts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,22 @@ pub static WASM_DIR: Lazy<PathBuf> = Lazy::new(|| {
}
});
pub static WEBSITE_RES_DIR: Lazy<PathBuf> = Lazy::new(|| {
#[cfg(debug_assertions)]
{
std::env::current_dir().unwrap().join("res")
}
#[cfg(not(debug_assertions))]
{
let mut path = std::env::var("ROOT_DIR")
.ok()
.map(|dir| Path::new(&dir).to_path_buf())
.expect("ROOT_DIR is not set");
path.push("website");
path
}
let mut path = {
#[cfg(debug_assertions)]
{
std::env::current_dir().unwrap().join("res")
}
#[cfg(not(debug_assertions))]
{
std::env::var("ROOT_DIR")
.ok()
.map(|dir| Path::new(&dir).to_path_buf())
.expect("ROOT_DIR is not set")
}
};

path.push("website");
path
});

pub static CACHE_DIR: Lazy<PathBuf> = Lazy::new(|| {
Expand Down

0 comments on commit 08c353f

Please sign in to comment.