# `HaAuth.Plug`
[🔗](https://github.com/drselump14/ha_auth/blob/v0.1.0/lib/ha_auth/plug.ex#L1)

Plugs for routes:

  * `plug HaAuth.Plug, :require_user` - assigns `:current_user`, or
    remembers the page (with its query) and sends the browser to `/login`
  * `plug HaAuth.Plug, :redirect_if_signed_in` - for the login routes
  * `plug HaAuth.Plug, :login_codes` - fresh QR code and kiosk nonce for
    the login page (used by `HaAuth.Router`)

---

*Consult [api-reference.md](api-reference.md) for complete listing*
