1// with npm
2npm install @mui/material @emotion/react @emotion/styled
3
4// with yarn
5yarn add @mui/material @emotion/react @emotion/styled
6
7// Icons
8// with npm
9npm install @mui/icons-material
10
11// with yarn
12yarn add @mui/icons-material
1
2CDN
3You can start using Material-UI with minimal Front-end infrastructure, which is great for prototyping.
4
5Two Universal Module Definition (UMD) files are provided:
6
7one for development: https://unpkg.com/@material-ui/core@latest/umd/material-ui.development.js
8one for production: https://unpkg.com/@material-ui/core@latest/umd/material-ui.production.min.js
9
10Material-UI is available as an npm package.
11
12npm
13To install and save in your package.json dependencies, run:
14
15// with npm
16npm install @material-ui/core
17
18// with yarn
19yarn add @material-ui/core
20
21
1import TextField from '@material-ui/core/TextField'
2
3<TextField
4 id="slots"
5 type="number"
6 min={1}
7 defaultValue="1"
8 className="TextField pa2"
9 onChange={handleChange}
10 label="number of slots"
11 InputProps={{
12 inputProps: { min: 1}
13 }}
14 InputLabelProps = {{
15 shrink:true,
16 }}/>