March 2019
Intermediate to advanced
534 pages
14h 52m
English
Once you know where you want to position your snackbars, you can create your own Snackbar component that has the anchorOrigin values defined. Here's an example:
const MySnackbar = props => ( <Snackbar anchorOrigin={{ vertical: 'top', horizontal: 'right' }} {...props} />);
Anywhere in your app that MySnackbar is used, the snackbars will be displayed in the top-right corner of the screen. Otherwise, MySnackbar is just like a regular Snackbar component.
Read now
Unlock full access