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

Function installServiceInEmbedDoc

src/service-helpers.js:52–62  ·  view source on GitHub ↗
(ampdoc, id, service)

Source from the content-addressed store, hash-verified

50 * @param {!Object} service The service.
51 */
52export function installServiceInEmbedDoc(ampdoc, id, service) {
53 registerServiceInternal(
54 getAmpdocServiceHolder(ampdoc),
55 ampdoc,
56 id,
57 function () {
58 return service;
59 },
60 /* override */ true
61 );
62}
63
64/**
65 * Installs a service override in the scope of an embedded window.

Callers 2

Calls 2

registerServiceInternalFunction · 0.85
getAmpdocServiceHolderFunction · 0.85

Tested by

no test coverage detected