shrub/mar/hook.hoon

52 lines
1.5 KiB
Plaintext
Raw Normal View History

::
2015-06-05 03:27:01 +03:00
:::: /hoon/hook/mar
::
/? 314
2015-02-27 09:35:41 +03:00
!:
|_ own=@t
::
++ grow :: convert to
|%
2014-09-30 01:56:09 +04:00
++ mime [/text/hoon (taco own)] :: convert to %mime
2015-06-06 01:20:26 +03:00
++ elem :: convert to %html
2015-05-21 01:13:27 +03:00
;div:pre(urb_codemirror ""):"{(trip own)}"
2015-05-20 06:29:04 +03:00
:: =+ gen-id="src-{<`@ui`(mug own)>}"
:: ;div
:: ;textarea(id "{gen-id}"):"{(trip own)}"
:: ;script:"""
:: CodeMirror.fromTextArea(
:: window[{<gen-id>}],
:: \{lineNumbers:true, readOnly:true}
:: )
:: """
:: ==
++ hymn
2015-06-06 01:20:26 +03:00
:: ;html:(head:title:"Source" "+{elem}")
2015-05-20 06:29:04 +03:00
;html
;head
;title:"Source"
;script@"//cdnjs.cloudflare.com/ajax/libs/codemirror/4.3.0/codemirror.js";
;script@"/{(trip &2:%)}/lib/syntax/hoon.js";
;link(rel "stylesheet", href "//cdnjs.cloudflare.com/ajax/libs/".
"codemirror/4.3.0/codemirror.min.css");
;link/"/{(trip &2:%)}/lib/syntax/codemirror.css"(rel "stylesheet");
==
;body
;textarea#src:"{(trip own)}"
;script:'CodeMirror.fromTextArea(src, {lineNumbers:true, readOnly:true})'
==
==
++ txt (lore (cat 3 own '\0a'))
--
2015-02-27 09:35:41 +03:00
++ grab
|% :: convert from
++ mime |=([p=mite q=octs] q.q)
++ noun ,@t :: clam from %noun
++ txt
|= wan=wain
=+ (role wan)
(end 3 (dec (met 3 -)) -)
--
2015-07-08 01:22:32 +03:00
++ grad %txt
2015-02-27 09:35:41 +03:00
--