(create-handler spec-path)Load spec-path and return a Ring handler ready to mount in any server. Use this when embedding BFF as a library in your own application.
Example: (require '[bff.core :as bff] '[bff.executor :as executor])
(executor/register-transformer! "my-transform" my-transform-fn)
(def handler (bff/create-handler "my-spec.yaml"))
;; plug handler into your existing Ring/Jetty/http-kit server
Load spec-path and return a Ring handler ready to mount in any server.
Use this when embedding BFF as a library in your own application.
Example:
(require '[bff.core :as bff]
'[bff.executor :as executor])
(executor/register-transformer! "my-transform" my-transform-fn)
(def handler (bff/create-handler "my-spec.yaml"))
;; plug handler into your existing Ring/Jetty/http-kit servercljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |