1.0.2 • Published 7 years ago
test-component-with-component-class-type
Licence
UNLICENSED
Version
1.0.2
Deps
25
Size
19 kB
Vulns
0
Weekly
0
withStyles Bugfix:
eigentliche Implementierung:
export interface NewComponentProps extends ComponentProps {...}
const InnerNewComponent: React.SFC<
NewComponentProps & WithStyles<typeof styles>
> = props => (
<Component>
...
</Component
)
export const NewComponent = withStyles(styles)(InnerNewComponent);
-> sorgt für Fehlermeldung
workaround:
export interface NewComponentProps extends ComponentProps {...}
interface InnerNewComponentProps extends WithStyles<typeof styles> {}
const InnerNewComponent: React.SFC<
NewComponentProps & InnerNewComponentProps
> = props => (
<Component>
...
</Component
)
export const NewComponent = withStyles(styles)(InnerNewComponent);