Skip to content

Commit

Permalink
add example (query) on readme
Browse files Browse the repository at this point in the history
Signed-off-by: Avelino <t@avelino.xxx>
  • Loading branch information
avelino committed Apr 14, 2020
1 parent 6b741ba commit eca0b23
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,11 @@ lein deps
:value "Google Cloud Datastore by cljs"}
{:name "url",
:value "https://github.com/avelino/cljs-google-datastore"}]]
(datastore/save ds "KEY-NAME" data)))

;; save data
(datastore/save ds "KEY-NAME" data)

;; get all records
(-> (datastore/query ds "KEY-NAME")
(.then (fn [r] (println r))))))
```

0 comments on commit eca0b23

Please sign in to comment.