MCPcopy Create free account
hub / github.com/cure53/DOMPurify / _isBasicCustomElement

Function _isBasicCustomElement

src/purify.ts:2428–2433  ·  view source on GitHub ↗
(tagName: string)

Source from the content-addressed store, hash-verified

2426 * @returns Returns true if the tag name meets the basic criteria for a custom element, otherwise false.
2427 */
2428 const _isBasicCustomElement = function (tagName: string): boolean {
2429 return (
2430 !RESERVED_CUSTOM_ELEMENT_NAMES[stringToLowerCase(tagName)] &&
2431 regExpTest(CUSTOM_ELEMENT, tagName)
2432 );
2433 };
2434
2435 /**
2436 * Wrap an attribute value in the matching Trusted Types object when

Callers 2

_sanitizeDisallowedNodeFunction · 0.85
_isValidAttributeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected