MCPcopy Create free account
hub / github.com/ampproject/amphtml / constructor

Method constructor

ads/inabox/position-observer.js:29–38  ·  view source on GitHub ↗

* @param {!Window} win

(win)

Source from the content-addressed store, hash-verified

27 * @param {!Window} win
28 */
29 constructor(win) {
30 /** @private {!Window} */
31 this.win_ = win;
32 /** @private {?Observable} */
33 this.positionObservable_ = null;
34 /** @protected {!Element} */
35 this.scrollingElement_ = getScrollingElement(this.win_);
36 /** @private {?LayoutRectDef} */
37 this.viewportRect_ = null;
38 }
39
40 /**
41 * Start to observe the target element's position change and trigger callback.

Callers

nothing calls this directly

Calls 1

getScrollingElementFunction · 0.70

Tested by

no test coverage detected