ce-la-react
Advanced tools
Comparing version 0.1.2 to 0.1.3
@@ -65,3 +65,3 @@ /** | ||
toAttributeName: (propName: string) => string; | ||
toAttributeValue: (propValue: unknown) => unknown; | ||
toAttributeValue: (propValue: unknown) => unknown | null | undefined; | ||
} | ||
@@ -68,0 +68,0 @@ export declare function defaultToAttributeName(propName: string): string; |
@@ -61,7 +61,12 @@ /** | ||
} | ||
const attrValue = IS_REACT_19_OR_NEWER ? v : toAttributeValue(v); | ||
if (attrName && attrValue !== void 0) { | ||
attrs[attrName] = attrValue; | ||
reactProps[attrName] = attrValue; | ||
const attrValue = toAttributeValue(v); | ||
if (attrName && attrValue != null) { | ||
attrs[attrName] = String(attrValue); | ||
if (!IS_REACT_19_OR_NEWER) { | ||
reactProps[attrName] = attrValue; | ||
} | ||
} | ||
if (attrName && IS_REACT_19_OR_NEWER) { | ||
reactProps[attrName] = v; | ||
} | ||
} | ||
@@ -68,0 +73,0 @@ if (typeof window !== "undefined") { |
{ | ||
"name": "ce-la-react", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "Create a React component from a custom element.", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19651
250