MCPcopy Create free account
hub / github.com/angular/angular / containsAttributes

Function containsAttributes

packages/platform-browser/src/browser/meta.ts:212–214  ·  view source on GitHub ↗
(tag: MetaDefinition, elem: HTMLMetaElement)

Source from the content-addressed store, hash-verified

210}
211
212function containsAttributes(tag: MetaDefinition, elem: HTMLMetaElement): boolean {
213 return Object.keys(tag).every((key) => elem.getAttribute(getMetaKeyMap(key)) === tag[key]);
214}
215
216function getMetaKeyMap(prop: string): string {
217 return Object.hasOwn(META_KEYS_MAP, prop) ? META_KEYS_MAP[prop] : prop;

Callers 1

_getOrCreateElementMethod · 0.85

Calls 3

getMetaKeyMapFunction · 0.85
keysMethod · 0.65
getAttributeMethod · 0.65

Tested by

no test coverage detected