made it possible to change layouts.

This commit is contained in:
Bryce Covert
2017-12-19 19:31:13 -08:00
parent 043e558a51
commit b1414ebe60
6 changed files with 120 additions and 54 deletions

View File

@@ -1,16 +1,23 @@
(ns auto-ap.effects
(:require-macros [cljs.core.async.macros :refer [go]])
(:require [re-frame.core :as re-frame]
[reagent.core :as reagent]
[auto-ap.subs :as subs]
[auto-ap.events :as events]
[cljs.reader :as edn]
[cljsjs.dropzone :as dz]
[auto-ap.routes :as routes]
[bidi.bidi :as bidi]
[cljs-http.client :as http]
[cljs.core.async :refer [<!]]))
[cljs.core.async :refer [<!]]
[auto-ap.pushy :as p]
[pushy.core :as pushy]))
(re-frame/reg-fx
:redirect
(fn [uri]
(println uri)
(pushy/set-token! p/history uri)))
(re-frame/reg-fx
:set-local-storage
(fn [[name value]]
(if value
(.setItem js/localStorage name value)
(.removeItem js/localStorage name ))))
(re-frame/reg-fx
:http