MCPcopy
hub / github.com/ampproject/amphtml / getObserver

Function getObserver

src/utils/display-observer.js:404–407  ·  view source on GitHub ↗

* @param {!Element} target * @return {!DisplayObserver}

(target)

Source from the content-addressed store, hash-verified

402 * @return {!DisplayObserver}
403 */
404function getObserver(target) {
405 registerServiceBuilderForDoc(target, SERVICE_ID, DisplayObserver);
406 return /** @type {!DisplayObserver} */ (getServiceForDoc(target, SERVICE_ID));
407}
408
409/**
410 * @param {?Array<boolean>} observations

Callers 5

observeDisplayFunction · 0.70
unobserveDisplayFunction · 0.70
measureDisplayFunction · 0.70
registerContainerFunction · 0.70
unregisterContainerFunction · 0.70

Calls 2

getServiceForDocFunction · 0.90

Tested by

no test coverage detected