shrub/mar/urb.hoon

32 lines
1.0 KiB
Plaintext
Raw Normal View History

2015-02-14 06:43:17 +03:00
::
2015-06-05 03:27:01 +03:00
:::: /hoon/urb/mar
2015-02-14 06:43:17 +03:00
::
/? 314
!:
2016-02-10 04:24:30 +03:00
|_ [dep=@uvH own=[[%html ~] [[%head ~] hed=marl] [[%body ~] tal=marl] ~]]
2015-02-14 06:43:17 +03:00
::
++ etag-js
'''
urb.waspAll = function(sel){
Array.prototype.map.call(document.querySelectorAll(sel), urb.waspElem)
}
if(urb.wasp){urb.waspAll('script'); urb.waspAll('link')}
'''
2015-02-14 06:43:17 +03:00
++ grow :: convert to
|%
++ mime [/text/html (taco html)] :: convert to %mime
++ html (crip (poxo hymn)) :: convert to %html
++ hymn :: inject dependencies
^- manx
2016-02-10 04:24:30 +03:00
=: hed.own :_(hed.own ;meta(charset "utf-8", urb_injected "");)
tal.own (welp tal.own ;script(urb_injected ""):"{(trip etag-js)}" ~)
==
2016-02-10 04:24:30 +03:00
?~ dep own
own(hed :_(hed.own ;script@"/~/on/{<dep>}.js"(urb_injected "");))
2015-02-14 06:43:17 +03:00
--
++ grab
|% :: convert from
++ noun ,[@uvH manx] :: clam from %noun
2015-02-14 06:43:17 +03:00
--
--