LoginSignup
1
0

MUI v5 の環境構築

Posted at

ルートディレクトリにて下記をインストール

MUIとemotionのインストール

npm install @mui/material @emotion/react @emotion/styled

emotionとは?

MUI v5内部で使用されているスタイリングソリューション。

フォントインストール

デフォルトではRobotoFontが適用

npm install @fontsource/roboto

SVGアイコンインストール

npm install @mui/icons-material

コンポーネント内でインポートして利用

import React from 'react'
import { Button } from '@mui/material'

function Button() {
  return (
    <div>
        <Button>Click Me!!!</Button>
    </div>
    
  )
}

export default Button
1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0