ibraheemdev / astra

Rust web servers without async/await.
MIT License
189 stars 4 forks source link

Serving static HTML etc files #14

Open David-OConnor opened 8 months ago

David-OConnor commented 8 months ago

Hi! How can I use astra to serve an HTML file? Thank you!

For example, how can I serve the rust docs using Astra? Thank you!

ibraheemdev commented 3 weeks ago

Sorry for the late reply, this issue slipped from my notifications.

You can use Body::wrap_reader to stream an HTML file response.