Skip to content

Commit

Permalink
unify namespace for deftwg; bump 0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
tiye committed Nov 17, 2018
1 parent 0dc6e99 commit 45df785
Show file tree
Hide file tree
Showing 9 changed files with 27 additions and 18 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ Cached rendering and diff/patch library designed for Cumulo project.
### API [![Clojars Project](https://img.shields.io/clojars/v/cumulo/recollect.svg)](https://clojars.org/cumulo/recollect)

```clojure
[cumulo/recollect "0.4.4"]
[cumulo/recollect "0.5.0"]
```

```clojure
(recollect.macros/deftwig twig-name [param] body)
(recollect.twig/deftwig twig-name [param] body)
(recollect.twig/render-twig twig-data old-data-twig)
(recollect.twig/conceal data-twig)
(recollect.diff/diff-twig a b {:key :id})
Expand Down
22 changes: 17 additions & 5 deletions calcit.edn

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion meyvn.edn
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

{:pom {:group-id "cumulo",
:artifact-id "recollect",
:version "0.4.4",
:version "0.5.0",
:name "Cached rendering and diff/patch library designed for Cumulo project."}
:packaging {:jar {:enabled true
:remote-repository {:id "clojars"
Expand Down
4 changes: 0 additions & 4 deletions polyfill/recollect/macros.cljs

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(ns recollect.macros)
(ns recollect.twig)

(defmacro deftwig [twig-name params & body]
`(defn ~twig-name [~@params]
Expand Down
4 changes: 2 additions & 2 deletions src/recollect/test.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[recollect.schema :as schema]
[recollect.util :refer [vec-add seq-add]]
[shadow.test.env :refer [register-test]]
[recollect.macros :refer [deftwig]]
[recollect.twig :refer [deftwig]]
[recollect.twig :refer [render-twig]]))

(deftest
Expand All @@ -19,7 +19,7 @@
b (B fx)
a1 (render-twig b a0)
options {:key :id}
changes [1]]
changes []]
(is (= changes (diff-twig a0 a1 options)))))

(deftest
Expand Down
3 changes: 2 additions & 1 deletion src/recollect/twig.cljs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@

(ns recollect.twig
(:require [recollect.types :refer [Twig twig?]] [recollect.util :refer [=seq literal?]]))
(:require [recollect.types :refer [Twig twig?]] [recollect.util :refer [=seq literal?]])
(:require-macros [recollect.twig]))

(declare render-map)

Expand Down
2 changes: 1 addition & 1 deletion src/recollect/twig/card.cljs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@

(ns recollect.twig.card (:require [recollect.macros :refer [deftwig]]))
(ns recollect.twig.card (:require [recollect.twig :refer [deftwig]]))

(deftwig twig-card (user date) {:user user, :date date})
2 changes: 1 addition & 1 deletion src/recollect/twig/container.cljs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

(ns recollect.twig.container
(:require [recollect.twig.card :refer [twig-card]] [recollect.macros :refer [deftwig]]))
(:require [recollect.twig.card :refer [twig-card]] [recollect.twig :refer [deftwig]]))

(deftwig
twig-container
Expand Down

0 comments on commit 45df785

Please sign in to comment.