Cargo Features

rust-embed has no features set by default.

rust-embed = { version = "8.0.0", features = ["debug-embed", "interpolate-folder-path", "compression", "mime-guess", "include-exclude", "actix", "warp-ex", "axum-ex", "poem-ex", "salvo-ex", "rocket"] }

Enables debug-embed of rust-embed-impl and rust-embed-utils


Enables interpolate-folder-path of rust-embed-impl

compression = include-flate

Enables compression of rust-embed-impl


Enables mime-guess of rust-embed-impl and rust-embed-utils


Enables include-exclude of rust-embed-impl and rust-embed-utils

actix = actix-web, mime_guess
warp-ex = mime_guess, tokio, warp
axum-ex = axum, mime_guess, tokio
poem-ex = hex, mime_guess, poem, tokio
salvo-ex = hex, mime_guess, salvo, tokio

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features.

include-flate compression?

Enables stable of include-flate ^0.2

actix-web actix?

With default features

mime_guess actix? axum-ex? poem-ex? salvo-ex? warp-ex?

With default (rev-mappings)

hex poem-ex? salvo-ex?

With default (std)

tokio axum-ex? poem-ex? salvo-ex? warp-ex?

With macros and rt-multi-thread

warp warp-ex?
rocket implicit feature
axum axum-ex?

Enables http1 and tokio of axum ^0.6

poem poem-ex?

With server

salvo salvo-ex?

Enables salvo ^0.16