@yonatanel Happy new year. Comparing with duct middleware configurations, you can do it with your current way. Ref: https://github.com/duct-framework/module.web/blob/master/src/duct/module/web.clj#L114-L124 This configuration contains both dependencies and configuration values.
How can I send PUT request from hiccup.form to duct with ataraxy? Currently, I write
;; view
(form-to {} [:put (str "/accounts/" id)]
;; ...
)
;; config.edn
:duct.module/ataraxy {"/accounts {[:put "/" id] [:accounts/update ^int id]}}
I receive POST request from form.
I know that web browser can send only GET/POST request, and form-to
generates <input type="hidden" name="_method" value="put">
tag, but how can I send PUT request with form-to
...?You'd need to do a POST and check the _method parameter, @blackawa.
So I think you'd need to do it through middleware