March 2019
Intermediate to advanced
534 pages
14h 52m
English
The two typefaces that are used in this example are imported:
import 'typeface-exo';import 'typeface-ubuntu';
In practice, you'll only import the font that your active theme uses, to reduce the size of your build. The roboto font that's used all throughout the examples in this book is imported by the Storybook index file, since this font is the default theme font and used in every example in this book.
Now that you've imported the typefaces, you've made the font family names available to the theme:
const roboto = createMuiTheme({ typography: { fontFamily: '"Roboto", "Helvetica", "Arial", sans-serif' }});const exo = createMuiTheme({ typography: { fontFamily: '"Exo", "Roboto", "Helvetica", "Arial", sans-serif' }});const ubuntu ...Read now
Unlock full access