From the course: Build Modern Web Apps with React, Hooks, State Management, and APIs Using Vite or Next.js

Unlock this course with a free trial

Join today to access over 25,200 courses taught by industry experts.

Project setup overview

Project setup overview

Hello and welcome back. I have set up a project which is using Tailwind CSS and it has dependencies exeos being installed. This project has three folders. One is the API folder which is having the API client. For the API client, we have an improvement where we are using our API URL in terms of a config file. We are not going to make a use of the config URL inside string in this file. So that's how it goes. You have to create a .env file and this env stands for environment file. It is always a professional and best practice to keep an env file and put all your configurations inside this. This can be some of the secrets, some passwords, and some of the URLs that you are going to hit. Because these are configurable, when you deploy your application, you can make the use of it and use the different environment variables based on the environment that you are using. So in production, you can have a different URL and inside your local environment, you can have a different URL. So this API…

Contents