UNPKG

aesthetic-react

Version:

React hooks, composers, and more for styling components with Aesthetic.

8 lines 627 B
import React from 'react'; import { StyleSheetFactory, ThemeSheet } from 'aesthetic'; import { WithStylesOptions, WithStylesWrappedProps, WithStylesWrapperProps, StyledComponent } from './types'; /** * Wrap a React component with an HOC that injects the defined style sheet as a prop. */ export default function withStyles<Theme = ThemeSheet, T = unknown>(styleSheet: StyleSheetFactory<Theme, T>, options?: WithStylesOptions): <Props extends object = {}>(WrappedComponent: React.ComponentType<Props & WithStylesWrappedProps<Theme>>) => StyledComponent<Props & WithStylesWrapperProps>; //# sourceMappingURL=withStyles.d.ts.map