| 1729 | var validatedAttributeNameCache = {}; |
| 1730 | |
| 1731 | function isAttributeNameSafe(attributeName) { |
| 1732 | if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { |
| 1733 | return true; |
| 1734 | } |
| 1735 | if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { |
| 1736 | return false; |
| 1737 | } |
| 1738 | if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { |
| 1739 | validatedAttributeNameCache[attributeName] = true; |
| 1740 | return true; |
| 1741 | } |
| 1742 | illegalAttributeNameCache[attributeName] = true; |
| 1743 | "development" !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; |
| 1744 | return false; |
| 1745 | } |
| 1746 | |
| 1747 | function shouldIgnoreValue(propertyInfo, value) { |
| 1748 | return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; |