Home > widget-integration > FilterController > document
FilterController.document property
The active DOM context for filter operations.
This document reference is set during filter initialization and can be different from the global document when working with specific DOM contexts, multiple filter instances, or when the filter is rendered in isolated containers.
Signature:
protected get document(): HTMLElement;
Remarks
All DOM queries within the filter should use this context instead of the global document to ensure operations are scoped correctly. This is particularly important for shops with multiple collection pages or dynamic filter instances.