Intermediate tagged template function returned by the styled function.
Values provided as part of a styled template string.
The styled
API returned by the createStyled factory function.
Create's a styled component when called as a function.
const StyledComponent = styled('div')``;
const StyledComponent = styled('div')<ExtraProps>``;
See also:
Create a global style component.
const GlobalStyle = styled.global``;
const GlobalStyle = styled.global<Props>``;
Create a style mixin function.
A style "mixin" is a function which returns a style string.
const mixin = styled.mixin``;
const mixin = styled.mixin<Props>``;
Create a React theme hook function and provider component.
const [useTheme, ThemeProvider, ThemeContext] = createReactTheme({ color: 'red' });
Get a stable ID string which is safe to use as a CSS identifier.
const id = getId('namespace');
Note: When process.env.NODE_ENV
is "test" (eg. during Jest testing),
this function returns a stable value for the given display name. This value
is NOT unique per invocation like it would be at runtime.
Get all of the <style>
elements (generated by TSStyled) as an HTML string.
Generated using TypeDoc
Style mixin functions returned by the {@link Styled.mixin styled.mixin} method.