We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb2fa2a commit ef5e134Copy full SHA for ef5e134
packages/primitives-core/src/styled.ts
@@ -51,7 +51,8 @@ export function createStyled(
51
52
// do we really want to use the same infra as the web since it only really uses theming?
53
let Styled = React.forwardRef<unknown, StyledProps>((props, ref) => {
54
- const finalTag = (shouldUseAs && props.as) || component
+ const finalTag =
55
+ (shouldUseAs && (props.as as React.ElementType)) || component
56
57
let mergedProps = props
58
if (props.theme == null) {
0 commit comments