caribou / caribou-core

Core functionality for Caribou
44 stars 3 forks source link

app model hooks #11

Closed ralfonso closed 12 years ago

ralfonso commented 12 years ago

I had to move the dir to resources/ but it works for me.

A hook file looks like this:

(require '[caribou.model :as model])

(defn hook-test
  [env]
  (println "HOOK FIRED!")
  env) 

(model/add-hook :person :before_update :dummy-test-hook hook-test)