MCPcopy Create free account
hub / github.com/Lobos/react-ui / validateDangerousTag

Function validateDangerousTag

docs/lib/react.js:6631–6636  ·  view source on GitHub ↗
(tag)

Source from the content-addressed store, hash-verified

6629var hasOwnProperty = {}.hasOwnProperty;
6630
6631function validateDangerousTag(tag) {
6632 if (!hasOwnProperty.call(validatedTagCache, tag)) {
6633 !VALID_TAG_REGEX.test(tag) ? "development" !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : invariant(false) : void 0;
6634 validatedTagCache[tag] = true;
6635 }
6636}
6637
6638function isCustomComponent(tagName, props) {
6639 return tagName.indexOf('-') >= 0 || props.is != null;

Callers 1

ReactDOMComponentFunction · 0.85

Calls 1

invariantFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…