diff --git a/resources/demo/notebook/clojure_edn.cljs b/resources/demo/notebook/clojure_edn.cljs new file mode 100644 index 0000000..b280602 --- /dev/null +++ b/resources/demo/notebook/clojure_edn.cljs @@ -0,0 +1,7 @@ +(ns demo.notebook.clojure-edn + (:require + [clojure.edn :as edn])) + +(def x (pr-str {:a 1 :b true :name "harry potter"})) + +(edn/read-string x) diff --git a/resources/demo/notebook/format.cljs b/resources/demo/notebook/format.cljs deleted file mode 100644 index 60be720..0000000 --- a/resources/demo/notebook/format.cljs +++ /dev/null @@ -1,21 +0,0 @@ -(ns demo.notebook.format - (:require - [tick.core :as t] - [tick.helper :refer [dt-format]] - [pinkgorilla.repl.cljs.js :refer [to-fixed]] - [goog.string :refer [format]])) - -(dt-format "YYYYMMdd HH:mm:ss" (t/now)) - -(format "hello %s !" "mr X.") - -(to-fixed 2.511 3) -(to-fixed 2.511 2) -(to-fixed 2.511 0) - -(format "%.3f" 2.511) -(format "%.2f" 2.511) -(format "%.0f" 2.511) -(format "%d" 134.44) -(format "%s %s %s" 2021 11 13) - diff --git a/resources/demo/notebook/tick.cljs b/resources/demo/notebook/tick.cljs index 706a963..4e4773b 100644 --- a/resources/demo/notebook/tick.cljs +++ b/resources/demo/notebook/tick.cljs @@ -3,4 +3,5 @@ [tick.core :as t] [tick.helper :refer [dt-format]])) -(dt-format "YYYYMMdd HH:mm:ss" (t/now)) \ No newline at end of file +(dt-format "YYYYMMdd HH:mm:ss" (t/now)) + diff --git a/resources/demo/notebook/to_fixed.cljs b/resources/demo/notebook/to_fixed.cljs new file mode 100644 index 0000000..d4b4d52 --- /dev/null +++ b/resources/demo/notebook/to_fixed.cljs @@ -0,0 +1,10 @@ +(ns demo.notebook.to-fixed + (:require + [pinkgorilla.repl.cljs.js :refer [to-fixed]])) + + + + +(to-fixed 2.511 3) +(to-fixed 2.511 2) +(to-fixed 2.511 0)