mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-01 20:04:09 +03:00
more tree 151ization
This commit is contained in:
parent
dafdf4d161
commit
6db85fe1ac
@ -38,6 +38,6 @@
|
||||
--
|
||||
++ grab
|
||||
|% :: convert from
|
||||
++ noun ,[@uvH manx] :: clam from %noun
|
||||
++ noun {@uvH manx} :: clam from %noun
|
||||
--
|
||||
--
|
||||
|
@ -13,6 +13,7 @@
|
||||
|%
|
||||
++ schema (dict {term $@(mark schema)})
|
||||
++ dict |*(a/_* $^({a (dict a)} a))
|
||||
++ plist (list {term $@(mark plist)})
|
||||
++ query
|
||||
$% {$kids p/(list query)}
|
||||
{$name $t}
|
||||
@ -27,16 +28,14 @@
|
||||
{$meta $j}
|
||||
{$mime $m}
|
||||
==
|
||||
++ to-queries
|
||||
|= a/schema ^- (list query)
|
||||
?@(-.a [(to-query a) ~] [(to-query -.a) $(a +.a)])
|
||||
++ schema-to-plist :: pad improper list
|
||||
|= a/schema ^- plist
|
||||
?@(-.a [(to-item a) ~] [(to-item -.a) $(a +.a)])
|
||||
::
|
||||
++ to-item
|
||||
|= b/{term $@(mark schema)} ^- {term $@(mark plist)}
|
||||
?@(+.b b [-.b (schema-to-plist +.b)])
|
||||
::
|
||||
++ to-query
|
||||
|= a/{term $@(mark schema)} ^- query
|
||||
~| invalid-query+a
|
||||
?+ -.a ;;(query a)
|
||||
$kids [%kids (to-queries ?@(+.a !! +.a))]
|
||||
==
|
||||
++ from-type :: XX holding out for noun odors
|
||||
|= a/$%({$t p/cord} {$r p/json} {$j p/json} {$m mime})
|
||||
?- -.a
|
||||
@ -76,4 +75,6 @@
|
||||
=+ ^= schem
|
||||
=+ seh=(fall (~(get by qix.gas) 'q') default)
|
||||
~|(bad-noun+seh ;;(schema (rash seh read-schem)))
|
||||
(from-queries bem.gas(s but.gas) (to-queries schem))
|
||||
%+ from-queries bem.gas(s but.gas)
|
||||
~| invalid-query+schem
|
||||
;;((list query) (schema-to-plist schem))
|
||||
|
@ -3,7 +3,7 @@
|
||||
::
|
||||
/? 314
|
||||
/+ urb-split :: for single-page apps
|
||||
/% /^ [hed=[@uvH marl] bod=[@uvH marl]]
|
||||
/% /^ {hed/{@uvH marl} bod/{@uvH marl}}
|
||||
/, /web/app
|
||||
/|(/;urb-split;/#/!hymn/ /urb-tree/)
|
||||
/
|
||||
|
Loading…
Reference in New Issue
Block a user