Closed binvb closed 2 years ago
Can you provide mini repo?
Can you provide mini repo?
i found the @latest version already fix this:
public update(el: HTMLElement, binding: string | DirectiveBinding<string | ValueFormatterObject>): void {
if (!el)
return
this._realObserver(el)?.unobserve(el)
const { src, error, lifecycle, delay } = this._valueFormatter(typeof binding === 'string' ? binding : binding.value)
this._initIntersectionObserver(el, src, error, lifecycle, delay)
}
but i was wondering when the el object will return null, it's glad to get your answer.
Can you provide mini repo?
i found the @latest version already fix this:
public update(el: HTMLElement, binding: string | DirectiveBinding<string | ValueFormatterObject>): void { if (!el) return this._realObserver(el)?.unobserve(el) const { src, error, lifecycle, delay } = this._valueFormatter(typeof binding === 'string' ? binding : binding.value) this._initIntersectionObserver(el, src, error, lifecycle, delay) }
but i was wondering when the el object will return null, it's glad to get your answer.
When the dom has not been mounted or after unmounted.
i was get error from user report, but i can not find why this happend, can you help?