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

Method assertElement

src/utils/log.js:414–420  ·  view source on GitHub ↗

* Throws an error if the first argument isn't an Element * * Otherwise see `assert` for usage * * @param {*} shouldBeElement * @param {!Array|string=} opt_message The assertion message * @return {!Element} The value of shouldBeTrueish. * @closurePrimitive {asserts.matchesReturn}

(shouldBeElement, opt_message)

Source from the content-addressed store, hash-verified

412 * @closurePrimitive {asserts.matchesReturn}
413 */
414 assertElement(shouldBeElement, opt_message) {
415 return assertions.assertElement(
416 this.boundAssertFn_,
417 shouldBeElement,
418 opt_message
419 );
420 }
421
422 /**
423 * Throws an error if the first argument isn't a string. The string can

Callers 15

output.jsFile · 0.80
input.jsFile · 0.80
input.jsFile · 0.80
input.jsFile · 0.80
helloFunction · 0.80
test-log.jsFile · 0.80
togglePlaceholderMethod · 0.80
onDocumentFormSubmit_Function · 0.80
insertStyleElementFunction · 0.80
setBodyVisibleStylesFunction · 0.80
isActionableByTapFunction · 0.80
importShadowBodyFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected