Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ axum = "0.8"

Use the `embed_assets!` macro to create a `static_router()` function in scope which will include your static files, embedding them into your binary:

```rust
```rust,ignore
use static_serve::embed_assets;

embed_assets!("assets", compress = true, ignore_paths = ["temp.txt","temp"], cache_busted_paths = ["immutable"]);
Expand Down Expand Up @@ -60,8 +60,9 @@ This will:

Use the `embed_asset!` macro to return a function you can use as a GET handler, which will include your static file, embedded into your binary:

```rust
use static_serve::embed_assets;
```rust,ignore
use axum::Router;
use static_serve::embed_asset;

let router: Router<()> = Router::new();
let handler = embed_asset!("assets/my_file.png", compress = true, cache_bust = true);
Expand Down Expand Up @@ -96,7 +97,7 @@ The crate automatically handles:

## Example

```rust
```rust,ignore
use axum::{Router, Server};
use static_serve::{embed_assets, embed_asset};

Expand Down
84 changes: 0 additions & 84 deletions static-serve/README.md

This file was deleted.

1 change: 1 addition & 0 deletions static-serve/README.md