jaemk / cached

Rust cache structures and easy function memoization
MIT License
1.57k stars 95 forks source link

Replace instant with web-time #214

Closed bernharddick closed 4 months ago

bernharddick commented 4 months ago

Replaces the now deprecated crate instant with web-time

jaemk commented 4 months ago

Thanks! Released 0.53.0

brandonweeks commented 4 months ago

Was it the intent of this change to pull in the wasm-bindgen collection of crates even when the wasm feature is not selected?

jaemk commented 4 months ago

The wasm feature actually isn't necessary anymore and could be removed. web_time only uses/exposes wasm functionality when compiling for the wasm target: https://docs.rs/web-time/latest/web_time/

At the same time the library will simply re-export std::time when not using the wasm32-unknown-unknown target and will not pull in any dependencies.