mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-11-11 04:48:00 +03:00
added tree heads.json generator
This commit is contained in:
parent
5e8bd1f2f5
commit
8039c0abba
@ -19,6 +19,7 @@
|
||||
head/(react-to-json ;h1:"*{hed}")
|
||||
body/(react-to-json ;div:"*{tal}")
|
||||
~
|
||||
++ react-head-json [%a (turn hed react-to-json)]
|
||||
:: ++ js react-snip-js
|
||||
++ react-snip-json (react-to-json elem)
|
||||
++ mime [/application/json (tact tape)]
|
||||
|
14
tree-gen/heads/json.hook
Normal file
14
tree-gen/heads/json.hook
Normal file
@ -0,0 +1,14 @@
|
||||
::
|
||||
:::: /hook/json/heads/tree-gen
|
||||
::
|
||||
/? 314
|
||||
/$ |= [[bek=beak *] but=spur]
|
||||
~&(scan/(tope bek ~)^`path`(flop but) ~)
|
||||
/= dat /: /=== /% /react-head-json/
|
||||
/= kid /: /%%/ /%
|
||||
/; |=(a=(map span json) `json`[%o a])
|
||||
/_ /json/
|
||||
!:
|
||||
::::
|
||||
::
|
||||
(jobe node/dat kids/kid ~)
|
6
tree/heads/json.hook
Normal file
6
tree/heads/json.hook
Normal file
@ -0,0 +1,6 @@
|
||||
::
|
||||
:::: /hook/json/heads/tree
|
||||
::
|
||||
/: /===tree-gen/heads /% 2 /json/
|
||||
~! .
|
||||
(joba %heads -.-)
|
@ -13,7 +13,4 @@
|
||||
%+ joba %kids
|
||||
=- [%a (turn (~(tap by dat)) -)]
|
||||
|= [a=span b=json]
|
||||
%- jobe :~
|
||||
name/s/a
|
||||
body/b
|
||||
==
|
||||
(jobe name/s/a body/b ~)
|
||||
|
@ -38,8 +38,4 @@
|
||||
=- [%a (turn (~(tap by dat)) -)]
|
||||
|= [a=span b=json]
|
||||
=+ fon=(json-front b)
|
||||
%- jobe :~
|
||||
meta/fon
|
||||
name/s/a
|
||||
body/b
|
||||
==
|
||||
(jobe meta/fon name/s/a body/b ~)
|
||||
|
Loading…
Reference in New Issue
Block a user