TSS
HomeGitHubPlayground
v3
v3
  • ๐Ÿš€Why TSS
  • ๐Ÿ”งSetup
  • ๐Ÿ”API References
    • makeStyles -> useStyles
    • withStyles
    • <GlobalStyles />
    • keyframes
    • useMergedClasses
  • ๐Ÿ’ฝCache
  • ๐Ÿ’ซNested selectors (ex $ syntax)
  • โšกSSR
    • Gatsby
    • Next.js
    • Other backends
  • ๐ŸฆฑYour own classes prop
  • ๐ŸญMUI Theme styleOverrides
  • ๐ŸงนDetecting unused classes
  • ๐Ÿ“ฆPublish a module that uses TSS
  • ๐Ÿ”ฉsingle-spa
  • ๐Ÿ“ฒReact Native
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub

API References

PreviousSetupNextmakeStyles -> useStyles

Last updated 2 years ago

Was this helpful?

Exposed APIs

import {
    createMakeAndWithStyles, //<- Create an instance of makeStyles() and withStyles() for your theme.
    keyframes, //<- The function as defined in @emotion/react and @emotion/css
    GlobalStyles, //<- A component to define global styles.
    TssCacheProvider, //<- Provider to specify the emotion cache tss should use.
    useCssAndCx, //<- Access css and cx directly.
    //   (Usually you'll use useStyles returned by makeStyles or createMakeStyles for that purpose
    //    but if you have no theme in your project, it can come in handy.)
    useMergedClasses //<- Merge the internal classes an the one provided as props into a single classes object.
} from "tss-react";
๐Ÿ”
makeStyles -> useStyles
withStyles
<GlobalStyles />
keyframes
useMergedClasses