• This function returns whether or not an element is within the viewable area of a container. If partial is true, then this function will return true even if only part of the element is in view.

    Parameters

    • container: HTMLElement

      The container to check if the element is in view of.

    • element: HTMLElement

      The element to check if it is view

    • partial: boolean

      true if partial view is allowed

    • Optionalstrict: boolean

      true if strict mode is set, never consider the container width and element width

    Returns boolean

    True if the component is in View.