The future of Popper is here! Floating UI is now available. Get it now!
Popper Logo
Popper Logo

Popper Offsets

The popperOffsets modifier is at the core of Popper, it computes the offsets needed to position the popper element near the reference element.

In other words, without this modifier you would have no reason to use Popper at all 😄

This piece of logic is written as a modifier because it makes it possible to run additional custom modifiers before it, for example, if you need to read from the DOM and manipulate the measurements made by Popper at the beginning of the lifecycle.

Additionally, you may want to replace this modifier with your own one, to address very specific cases not covered by the default one.

Don't mind tech-related ads? Consider disabling your ad-blocker to help us!
They are small and unobtrusive.
Alternatively, support us on Open Collective!

Phase

read

Options

This modifier currently has no options.

Data

type Data = {
  x: number,
  y: number,
};
Edit this page
Modifiers
© 2024 MIT License