Module layout_element

Module layout_element 

Source

Traitsยง

DangerousStyleElement
An element that can be passed to stylo and selectors that allows accessing the parent node. We consider this to be too dangerous for normal layout, so it is reserved only for using stylo and selectors.
LayoutElement
A trait that exposes a DOM element to layout. Implementors of this trait must abide by certain safety requirements. Layout will only ever access and mutate each element from a single thread at a time, though children may be used in parallel from other threads. That is why this trait does not allow access to parent nodes, as it would make it easy to cause race conditions and memory errors.