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

Function DEFAULT_GET_JSON

extensions/amp-render/1.0/component.js:18–20  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

16 * @return {!Promise<!JsonObject>}
17 */
18const DEFAULT_GET_JSON = (url) => {
19 return fetch(url).then((res) => res.json());
20};
21
22/**
23 * @param {!RenderDef.Props} props

Callers

nothing calls this directly

Calls 3

fetchFunction · 0.85
thenMethod · 0.45
jsonMethod · 0.45

Tested by

no test coverage detected