Skip to content

Commit def918a

Browse files
committed
check props with lilac; alpha release
1 parent 354ea81 commit def918a

File tree

6 files changed

+184
-2
lines changed

6 files changed

+184
-2
lines changed

calcit.cirru

Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,23 @@
4848
|j $ {} (:type :leaf) (:id |B1BWif6J3sW) (:text "|\"fs") (:by |root) (:at 1540914796490)
4949
|r $ {} (:type :leaf) (:id |HyUWoz6yhjZ) (:text |:as) (:by |root) (:at 1506700563333)
5050
|v $ {} (:type :leaf) (:id |SkwZizakniZ) (:text |fs) (:by |root) (:at 1506700563333)
51+
|t $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758604704)
52+
:data $ {}
53+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758605109) (:text |[]) (:id |0Datg9luSoleaf)
54+
|j $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758608842) (:text |lilac.core) (:id |rMdg4paeql)
55+
|r $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758609582) (:text |:refer) (:id |c06B3Qxkjw)
56+
|v $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758609827)
57+
:data $ {}
58+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758610098) (:text |[]) (:id |P13hLmeFJ4)
59+
|j $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758611787) (:text |dev-check) (:id |G-NLhNqFKE)
60+
|r $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758633805) (:text |record+) (:id |ZttyBa6g_n)
61+
|v $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758635682) (:text |string+) (:id |hGHy5h7wv)
62+
|x $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758647627) (:text |vector+) (:id |qLauNV7n3)
63+
|y $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758690845) (:text |optional+) (:id |XqH_w2OUad)
64+
|yT $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758811999) (:text |or+) (:id |p-m2wdLPsp)
65+
|yj $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758847119) (:text |keyword+) (:id |yC2Bhu0jt-)
66+
:id |lVeDoVeDxK
67+
:id |0Datg9luSo
5168
:defs $ {}
5269
|make-page $ {} (:type :expr) (:id |BytWiM6J3j-) (:by nil) (:at 1506700563333)
5370
:data $ {}
@@ -495,6 +512,12 @@
495512
:data $ {}
496513
|T $ {} (:type :leaf) (:id |rkGsof6y3sZ) (:text |:append-html) (:by |root) (:at 1506700673588)
497514
|j $ {} (:type :leaf) (:id |SyXiiMpkniZ) (:text |resources) (:by |root) (:at 1506700563333)
515+
|xT $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758598381)
516+
:data $ {}
517+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758600896) (:text |dev-check) (:id |jJ_eD9QtMQleaf)
518+
|j $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758619192) (:text |resources) (:id |_HlXC-x2o)
519+
|r $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758624180) (:text |lilac-resource) (:id |bDcn3L5T8T)
520+
:id |jJ_eD9QtMQ
498521
|slurp $ {} (:type :expr) (:id |HJAhjzaJ2j-) (:by nil) (:at 1506700563333)
499522
:data $ {}
500523
|T $ {} (:type :leaf) (:id |Bkyaszak3i-) (:text |defn) (:by |root) (:at 1506700563333)
@@ -587,6 +610,148 @@
587610
:id |tHjLws6CBf
588611
:id |Su2rDSkFv6
589612
:id |H7QL3MR75Z
613+
|lilac-resource $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758627114)
614+
:data $ {}
615+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758627114) (:text |def) (:id |r58lHZXXqW)
616+
|j $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758627114) (:text |lilac-resource) (:id |tD9Mei6W5t)
617+
|r $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758627114)
618+
:data $ {}
619+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758653451) (:text |record+) (:id |Fcm0awJSF)
620+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758665413)
621+
:data $ {}
622+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758665778) (:text |{}) (:id |69hijukR5)
623+
|yr $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
624+
:data $ {}
625+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758733960) (:text |:append-html) (:id |2-od6jvugZ)
626+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
627+
:data $ {}
628+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
629+
:id |xoPHkEW28y
630+
:id |YWJ6X-AvdN
631+
|yT $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
632+
:data $ {}
633+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758716224) (:text |:scripts) (:id |2-od6jvugZ)
634+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758719616)
635+
:data $ {}
636+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758815571)
637+
:data $ {}
638+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758817880)
639+
:data $ {}
640+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
641+
:data $ {}
642+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
643+
:id |xoPHkEW28y
644+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758825962) (:text |[]) (:id |ANDub5K8x)
645+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758826502)
646+
:data $ {}
647+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758828572) (:text |record+) (:id |XT8OCQamIcleaf)
648+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758828992)
649+
:data $ {}
650+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758829359) (:text |{}) (:id |2mJjh3saaE)
651+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758829662)
652+
:data $ {}
653+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758832669) (:text |:type) (:id |Vbqf4jvTfV)
654+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758840399)
655+
:data $ {}
656+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758844401) (:text |keyword+) (:id |pvJqZp08L)
657+
:id |odW9LcMgXE
658+
:id |6Oa29UHFle
659+
|r $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758834516)
660+
:data $ {}
661+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758836221) (:text |:src) (:id |NII_VnhEFleaf)
662+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758837688)
663+
:data $ {}
664+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758838763) (:text |string+) (:id |8XRWSWEMqB)
665+
:id |bUuNAGL83A
666+
:id |NII_VnhEF
667+
:id |g-bv-a6rL7
668+
:id |XT8OCQamIc
669+
:id |NgBU_f1W07
670+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758817053) (:text |or+) (:id |YsAZ4WykNx)
671+
:id |9-RVrTFqy
672+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758722279) (:text |vector+) (:id |KjyYWm6Ty3)
673+
:id |ikWImu6XXM
674+
:id |7gTZAuJ2Mg
675+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
676+
:data $ {}
677+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758674267) (:text |:title) (:id |2-od6jvugZ)
678+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
679+
:data $ {}
680+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
681+
:id |xoPHkEW28y
682+
:id |yMXP9b67-
683+
|x $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
684+
:data $ {}
685+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758708220) (:text |:styles) (:id |2-od6jvugZ)
686+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758698286)
687+
:data $ {}
688+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
689+
:data $ {}
690+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
691+
:id |xoPHkEW28y
692+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758699929) (:text |vector+) (:id |am6JElV3MD)
693+
:id |7NLjLLu8V
694+
:id |oST0kdLQMG
695+
|v $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
696+
:data $ {}
697+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758683858) (:text |:ssr) (:id |2-od6jvugZ)
698+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758685063)
699+
:data $ {}
700+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
701+
:data $ {}
702+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
703+
:id |xoPHkEW28y
704+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758687947) (:text |optional+) (:id |poaUX4Mt_n)
705+
:id |FX9a6e7n7
706+
:id |gv-g9KsDPg
707+
|yj $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
708+
:data $ {}
709+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758730471) (:text |:inner-html) (:id |2-od6jvugZ)
710+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758745553)
711+
:data $ {}
712+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758745553) (:text |string+) (:id |mPvY6c6wYW)
713+
:id |3dRAcuCDMb
714+
:id |SDVZ5zvIp
715+
|r $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
716+
:data $ {}
717+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758681591) (:text |:icon) (:id |2-od6jvugZ)
718+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
719+
:data $ {}
720+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
721+
:id |xoPHkEW28y
722+
:id |0ttNkxXgT
723+
|y $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758666091)
724+
:data $ {}
725+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758709131) (:text |:inline-styles) (:id |2-od6jvugZ)
726+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758710931)
727+
:data $ {}
728+
|T $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758675729)
729+
:data $ {}
730+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758676831) (:text |string+) (:id |DBQbfxVguO)
731+
:id |xoPHkEW28y
732+
|D $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758712619) (:text |vector+) (:id |YeYsRlQhV)
733+
:id |VqFEq1dcMp
734+
:id |Wbojf3V6-8
735+
|yv $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758756194)
736+
:data $ {}
737+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758757676) (:text |:manifest) (:id |yw3lR8mr7leaf)
738+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758758696)
739+
:data $ {}
740+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758762293) (:text |string+) (:id |2Jz6sjRmh)
741+
:id |8zk9of_ixk
742+
:id |yw3lR8mr7
743+
:id |lzxLyRn7J
744+
|r $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758764099)
745+
:data $ {}
746+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758764542) (:text |{}) (:id |ZJUqzvvSileaf)
747+
|j $ {} (:type :expr) (:by |UI0sFmATo) (:at 1592758764817)
748+
:data $ {}
749+
|T $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758768969) (:text |:all-optional?) (:id |dmt45nHL8H)
750+
|j $ {} (:type :leaf) (:by |UI0sFmATo) (:at 1592758769559) (:text |true) (:id |yh0I0biy_)
751+
:id |8J721FxYb3
752+
:id |ZJUqzvvSi
753+
:id |S5IaGUFMwF
754+
:id |sNB_I3lh7P
590755
:proc $ {} (:type :expr) (:id |rJOZszpkhj-) (:by nil) (:at 1506700563333) (:data $ {})
591756
|shell-page.main $ {}
592757
:ns $ {} (:type :expr) (:id |Sks0oz6kns-) (:by nil) (:at 1506700563333)

deps.edn

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
:release {
66
:extra-deps {
77
applied-science/deps-library {:mvn/version "0.4.0"}
8+
mvc-works/lilac {:mvn/version "0.1.6"}
89
}
910
:main-opts ["-m" "applied-science.deps-library"]
1011
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shell-page",
3-
"version": "0.1.11",
3+
"version": "0.1.2-a1",
44
"main": "index.js",
55
"repository": "git@github.com:mvc-works/shell-page.git",
66
"author": "jiyinyiyong <jiyinyiyong@gmail.com>",

release.edn

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{:version "0.1.11",
1+
{:version "0.1.12-a1",
22
:group-id "mvc-works",
33
:artifact-id "shell-page",
44
:skip-tag true,

shadow-cljs.edn

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
:source-paths ["src/"]
33
:dependencies [
44
[respo "0.12.2"]
5+
[mvc-works/lilac "0.1.6"]
56
]
67
:dev-http {7000 "target/"}
78
:builds {

src/shell_page/core.cljs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,29 @@
44
:refer
55
[html <> head title script style meta' div link body style list->])
66
[respo.render.html :refer [make-string]]
7+
[lilac.core :refer [dev-check record+ string+ vector+ optional+ or+ keyword+]]
78
["fs" :as fs]))
89

910
(defn get-indexed [xs]
1011
(->> xs (map-indexed (fn [idx x] [idx x])) (filter (fn [[idx x]] (some? x)))))
1112

13+
(def lilac-resource
14+
(record+
15+
{:title (string+),
16+
:icon (string+),
17+
:ssr (optional+ (string+)),
18+
:styles (vector+ (string+)),
19+
:inline-styles (vector+ (string+)),
20+
:scripts (vector+ (or+ [(string+) (record+ {:type (keyword+), :src (string+)})])),
21+
:inner-html (string+),
22+
:append-html (string+),
23+
:manifest (string+)}
24+
{:all-optional? true}))
25+
1226
(defn make-page [html-content resources]
1327
(assert (string? html-content) "1st argument should be string")
1428
(assert (map? resources) "2nd argument should be hashmap")
29+
(dev-check resources lilac-resource)
1530
(make-string
1631
(html
1732
{}

0 commit comments

Comments
 (0)