Add initial React client setup with Tailwind CSS integration
This commit is contained in:
57
README.md
57
README.md
@@ -1,8 +1,59 @@
|
||||
# ASPReactDemo
|
||||
|
||||
# ASPReactDemo
|
||||
|
||||
Eine Demo für:
|
||||
-ASP Net Core
|
||||
-Nswag
|
||||
-SignalR
|
||||
-React
|
||||
-Syncfusion
|
||||
-Syncfusion
|
||||
|
||||
## Installation React
|
||||
|
||||
### With Yarn
|
||||
|
||||
```bash
|
||||
yarn create react-app react-client --template typescript
|
||||
|
||||
cd react-client
|
||||
|
||||
yarn build
|
||||
|
||||
yarn start
|
||||
```
|
||||
## Installation tailwindcss
|
||||
|
||||
### Install and Init
|
||||
|
||||
```bash
|
||||
yarn add tailwindcss postcss autoprefixer
|
||||
|
||||
npx tailwindcss init -p
|
||||
|
||||
```
|
||||
|
||||
### Configure the tailwind.config.js File
|
||||
|
||||
Update the tailwind.config.js file to specify the paths to all of your template files. Replace the default content with the following (if not already present):
|
||||
|
||||
```javascript
|
||||
module.exports = {
|
||||
purge: ['./src/**/*.{js,jsx,ts,tsx}', './public/index.html'],
|
||||
darkMode: false, // or 'media' or 'class'
|
||||
theme: {
|
||||
extend: {},
|
||||
},
|
||||
variants: {
|
||||
extend: {},
|
||||
},
|
||||
plugins: [],
|
||||
}
|
||||
```
|
||||
|
||||
### Add Tailwind directives to your CSS:
|
||||
|
||||
|
||||
```css
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user