MCPcopy
hub / github.com/darkroomengineering/lenis / on

Method on

packages/core/src/lenis.ts:277–279  ·  view source on GitHub ↗
(event: LenisEvent, callback: ScrollCallback | VirtualScrollCallback)

Source from the content-addressed store, hash-verified

275 on(event: 'scroll', callback: ScrollCallback): () => void
276 on(event: 'virtual-scroll', callback: VirtualScrollCallback): () => void
277 on(event: LenisEvent, callback: ScrollCallback | VirtualScrollCallback) {
278 return this.emitter.on(event, callback as (...args: unknown[]) => void)
279 }
280
281 /**
282 * Remove an event listener for the given event and callback

Callers 8

provider.tsxFile · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
setupFunction · 0.45
browser.jsFile · 0.45
test.tsFile · 0.45
browser.jsFile · 0.45
browser.jsFile · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected