<!--
title: Use design system tokens
domain: app-frameworks
topic: Code Style
language: TSX
source: mui/material-ui
updated: 2025-06-18
url: https://awesomereviewers.com/reviewers/material-ui-use-design-system-tokens/
-->

{% raw %}
Always use design system tokens (theme values, breakpoints, spacing units) instead of hard-coded values. This ensures consistency across the codebase and makes maintenance easier when design changes are needed.

Bad:
```tsx
<Grid sx={{ 
  width: '44px',
  fontWeight: 'bold',
  '@media (max-width: 640px)': {
    // ...
  }
}} />
```

Good:
```tsx
<Grid sx={{ 
  width: theme.spacing(5.5), // or appropriate token
  fontWeight: theme.typography.fontWeightBold,
  [theme.breakpoints.down('sm')]: {
    // ...
  }
}} />
```

This practice:
- Maintains visual consistency
- Simplifies theme customization
- Makes responsive design more maintainable
- Reduces the need for magic numbers in the code
{% endraw %}
