Instale as dependências / Install all the dependencies:
npm install
Crie um arquivo .env na pasta de frontend e adicione a URL da API como variável de ambiente no seguinte formato / Create an .env file in frontend folder and add the API URL on the following format:
Create .env
VITE_BASE_URL=http://localhost:3000/
Execute o frontend / Execute the frontend:
npm run dev
Crie um arquivo .env na pasta de backend e adicione sua secret key do JWT e a porta que irá rodar seu projeto como variável de ambiente no seguinte formato / Create a .env file in the backend folder and add your JWT secret key and the port that will run your project as an environment variable in the following format.
Create .env
PORT=3000
JWT_SECRET=sua-chave-secreta
Execute o backend / Execute the backend:
npm start
├── backend 📁
│ ├── controllers 📁
│ │ ├── AuthControllers.ts 🌐
│ │ └── TransactionsControllers.ts 🌐
│ ├── db 📁
│ │ ├── transactions.json
│ │ └── user.json 🌐
│ ├── middleware 📁
│ │ └── authMiddleware.json 🌐
│ └── routes 📁
│ ├── authRoutes.json 🌐
│ └── transactionRoutes.json 🌐
│
├── frontend 📁
│ └── src 📁
│ ├── @types 📁
│ │ ├── Auth.ts 🌐
│ │ ├── TodoList.ts 🌐
│ │ └── Transactions.ts 🌐
│ ├── components 📁
│ │ └── routes 📁
│ │ └── privateRoutesService.tsx 🌐
│ │ └── Header 📁
│ │ └── Header.tsx 🌐
│ ├── context 📁
│ │ ├── AuthContext.ts 🌐
│ │ └── TransactionsContext.ts 🌐
│ ├── pages 📁
│ │ ├── Home 📁
│ │ ├── Login 📁
│ │ ├── TodoList 📁
│ │ └── Transactions 📁
│ ├── routes 📁
│ │ └── routes.tsx 🌐
│ ├── services 📁
│ │ ├── api.ts 🌐
│ │ ├── Auth 📁
│ │ │ └── authService.ts 🌐
│ │ └── Transactions 📁
│ │ └── transactionsService.ts 🌐
│ ├── styles 📁
│ │ ├── global.ts 🌐
│ │ └── variables.ts 🌐
│ ├── utils 📁
│ │ ├── transactions.ts 🌐
│ ├── App.tsx 🌐
│ └── main.tsx 🌐
- Fork it (
https://github.com/mariaelizasa/frontend-case.git
) - Create your feature branch (
git checkout -b feature/fooBar
) - Commit your changes (
git commit -am 'Add some fooBar'
) - Push to the branch (
git push origin feature/fooBar
- Create a new Pull Request
💡 Vamos construir juntos! / Let's build together! 💡