class-method
flagrate.Element.wrap
flagrate.Element.wrap(element, wrapper[, attribute]) → Element
element
(Element
) –wrapper
(Element
|String
) – An element to wrap `element` inside, or else a string representing the tag name of an element to be created.attribute
(Object
) – A set of attributes to apply to the wrapper element. Refer to the flagrate.Element constructor for usage.
Wraps an element inside another, then returns the wrapper.
This method is similar to http://api.prototypejs.org/dom/Element/wrap/