#static-file #debug-mode #generate-static #router #dynamically #routes #statically

static-router

(For Axum) Provides a macro to generate a static file router that serves the directory dynamically in debug mode and statically embeds the files and routes in release mode

2 releases

0.1.5 Sep 7, 2022
0.1.4 Sep 6, 2022
0.1.0 Aug 23, 2022

#19 in #generate-static

Download history 10/week @ 2024-02-25 1/week @ 2024-03-03 7/week @ 2024-03-10 1/week @ 2024-03-17 88/week @ 2024-03-24

98 downloads per month
Used in dexr

MIT/Apache

8KB
131 lines

Static Router

(For Axum)

Provides a macro to generate a static file router that serves the directory dynamically in debug mode and statically embeds the files and routes in release mode.

License

Licensed under either of Apache License, Version 2.0 or MIT license at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.


lib.rs:

To get started, see the static_router! macro.

Dependencies

~8–19MB
~235K SLoC