Add undo API

This commit is contained in:
Mike Thompson 2016-06-14 21:09:21 +10:00
parent 2822dc064a
commit 6250c584da
1 changed files with 12 additions and 1 deletions

View File

@ -4,6 +4,7 @@
[re-frame.subs :as subs]
[re-frame.router :as router]
[re-frame.utils :as utils]
[re-frame.undo :as undo]
[re-frame.middleware :as middleware]))
@ -23,7 +24,6 @@
(def pure middleware/pure)
(def debug middleware/debug)
(def undoable middleware/undoable)
(def path middleware/path)
(def enrich middleware/enrich)
(def trim-v middleware/trim-v)
@ -31,6 +31,17 @@
(def on-changes middleware/on-changes)
;; -- Undo API -----
;;
;; https://github.com/Day8/re-frame/wiki/Undo-&-Redo
(def undoable undo/undoable)
(def set-max-undos! undo/set-max-undos!)
(def set-undo-path! undo/set-undo-path!)
;; -- Logging -----
;; re-frame uses the logging functions: warn, log, error, group and groupEnd
;; By default, these functions map directly to the js/console implementations,