Cargo Features

[dependencies]
roa = { version = "0.6.1", default-features = false, features = ["full", "runtime", "json", "multipart", "urlencoded", "file", "template", "tcp", "tls", "cookies", "jwt", "router", "websocket", "compress", "async_rt", "jsonrpc", "docs"] }
default full? = async_rt

The async_rt feature is set by default whenever roa is added without default-features = false somewhere in the dependency tree.

full docs? = compress, cookies, default, file, json, jsonrpc, jwt, multipart, router, template, tls, urlencoded, websocket
runtime async_rt

Enables runtime of roa-core

json full? = serde, serde_json

Affects body::PowerBody.read_json, body::PowerBody.write_json

multipart full? = mime, multer

Affects body::PowerBody.read_multipart

urlencoded full? = serde, serde_urlencoded

Affects body::PowerBody.read_form

file full? = mime_guess

Enables fs of tokio

Affects body::PowerBody.write_file

template full? = askama

Affects body::PowerBody.render

tcp async_rt

Enables net and time of tokio

Affects roa::tcp

tls full? = rustls, rustls-pemfile, tokio-rustls

Affects roa::tls

cookies full? = cookie

Affects roa::cookie

jwt full? = jsonwebtoken, serde, serde_json

Affects roa::jwt

router full? = doc-comment, radix_trie, regex

Affects roa::router

websocket full? = tokio-tungstenite

Affects roa::websocket

compress full? = async-compression

Affects roa::compress

async_rt default = runtime, tcp
jsonrpc full? = jsonrpc-v2

Affects roa::jsonrpc

docs = full

Enables docs of roa-core

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

Enables cookie ^0.15

jsonwebtoken jwt?

Enables jsonwebtoken ^7.2

serde json? jwt? urlencoded?
serde_json json? jwt?
async-compression compress?

Enables async-compression ^0.3.8

radix_trie router?

Enables radix_trie

router

regex router?
askama template?

Enables askama ^0.10

body

doc-comment router?
serde_urlencoded urlencoded?
mime_guess file?
multer multipart?

Enables multer ^2.0

mime multipart?
tokio-tungstenite websocket?

Enables tokio-tungstenite ^0.15.0

websocket

rustls tls?

Enables rustls ^0.20

tls

tokio-rustls tls?

Enables tokio-rustls ^0.23

rustls-pemfile tls?

Enables rustls-pemfile ^0.2

jsonrpc-v2 jsonrpc?

Enables jsonrpc-v2 ^0.10

jsonrpc