Initialize a new React.js project:
Install project dependencies:
Install Tailwind CSS IntelliSense in editor setup VS Code
Add the files in index.css
@import "tailwindcss/base"; @import "tailwindcss/components"; @import "tailwindcss/utilities";
Start the development server:
Building for production:
Create .env
file in the root directory
and provide variables
VITE_USER_ID = "123"
In front end, variables loaded like this.
import.meta.env.VITE_USER_ID
run development server
npm start
Dotenv is a zero-dependency module that loads environment variables from a .env file into process.env.
npm i react-shimmer-effects
Mac (macOS): Shift + Option + F Windows: Shift + Alt + F Linux/Ubuntu: Ctrl + Shift + I.