MCPcopy
hub / github.com/fanmingming/live / validateComponentName

Function validateComponentName

m3u8/vue.js:1411–1424  ·  view source on GitHub ↗
(name)

Source from the content-addressed store, hash-verified

1409 }
1410
1411 function validateComponentName (name) {
1412 if (!new RegExp(("^[a-zA-Z][\\-\\.0-9_" + (unicodeRegExp.source) + "]*$")).test(name)) {
1413 warn(
1414 'Invalid component name: "' + name + '". Component names ' +
1415 'should conform to valid custom element name in html5 specification.'
1416 );
1417 }
1418 if (isBuiltInTag(name) || config.isReservedTag(name)) {
1419 warn(
1420 'Do not use built-in or reserved HTML elements as component ' +
1421 'id: ' + name
1422 );
1423 }
1424 }
1425
1426 /**
1427 * Ensure all props option syntax are normalized into the

Callers 3

checkComponentsFunction · 0.85
initExtendFunction · 0.85
initAssetRegistersFunction · 0.85

Calls 1

warnFunction · 0.85

Tested by

no test coverage detected