robertwayne / axum-htmx

A set of htmx extractors, responders, and request guards for axum.
Apache License 2.0
171 stars 8 forks source link

How to actually use responders? #22

Closed its-danny closed 1 month ago

its-danny commented 1 month ago

This may be more of an Axum question, but I can’t figure it out. I have a handler that, at the moment, returns impl IntoResponse; either (StatusCode, String) or Redirect.

I need to replace the Redirect with HxRedirect, but it doesn’t implement IntoResponse.

It’s not clear to me how to, like, return an empty response with the headers set via HxRedirect.