Manually compiles a page fragment that has been inserted into the DOM by external code.
All registered compilers and macros will be called
with matches in the given element
.
As long as you manipulate the DOM using Unpoly, you will never
need to call up.hello()
. You only need to use up.hello()
if the
DOM is manipulated without Unpoly' involvement, e.g. by setting
the innerHTML
property:
element = document.createElement('div')
element.innerHTML = '... HTML that needs to be activated ...'
up.hello(element)
This function emits the up:fragment:inserted
event.
The compiled element