Edit this page

up.fragment :origin
HTML selector

This feature is experimental. It may be changed or removed in a future version.

Your target selectors may use this pseudo-selector to reference the element that triggered the change.

The origin element is automatically set to a link that is being followed or form that is being submitted. When updating fragments programmatically through up.render() you may pass an origin element as an { origin } option.

Even without using an :origin reference, the origin is considered when matching fragments in the current page.


Instead of :origin you may also use the ampersand character (&).

You may be familiar with the ampersand from the Sass CSS preprocessor.

This website uses cookies to improve usability and analyze traffic.
I accept or learn more