This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-07-14
Channels
- # aleph (4)
- # announcements (1)
- # beginners (40)
- # calva (6)
- # cider (10)
- # clara (5)
- # cljdoc (24)
- # cljs-dev (2)
- # clojure (24)
- # clojure-italy (4)
- # clojure-uk (5)
- # clojurescript (13)
- # community-development (5)
- # core-async (7)
- # data-science (9)
- # datomic (2)
- # duct (12)
- # emacs (3)
- # events (1)
- # figwheel-main (2)
- # fulcro (2)
- # malli (1)
- # off-topic (1)
- # parinfer (1)
- # precept (6)
- # re-frame (27)
- # shadow-cljs (5)
- # sql (6)
- # unrepl (2)
does anyone know how to get the DateTime from a json+transit encoded string?
It looks like this:
[TaggedValue: LocalDateTime, 2019-07-14T00:06:25.433]
. I have tried various routes including using cognitec/transit but I can't seem to get this date out. Please help(:import [goog.date DateTime])
...
(def goog-utc-writer
(t/write-handler
(constantly "m")
#(.getTime %)
#(str (.getTime %))))
(def json-reader (t/reader :json {:handlers {cljs.core/Keyword (t/KeywordHandler.)
goog.date.UtcDateTime goog-utc-writer
goog.date.DateTime goog-utc-writer}}))
(def json-writer (t/writer :json {:handlers {cljs.core/Keyword (t/KeywordHandler.)
goog.date.UtcDateTime goog-utc-writer
goog.date.DateTime goog-utc-writer}}))
(def joda-time-writer
(t/write-handler
(constantly "m")
#(-> % coerce/to-date .getTime)
#(-> % coerce/to-date .getTime .toString)))
(def writer (t/writer out :json
{:handlers {org.joda.time.DateTime joda-time-writer}}))
Did anyone tried to run clojurescript inside phonegap? I couldn't find any sample on github.
Maybe not ClojureScript specific question, but anyone has some insights on using web workers? Are they good/bad ideas? What are the rookie mistakes with them?
I have looked Butler and Servant as library, but I wanted to know what kind of problems I could get into when I use them :)