6d59b9669e94435a3edbf3cad6b0b8445834595a
Tavily Comparison App
This project is a simple React application that allows users to compare three entities by fetching data from the Tavily API and displaying the results in a table.
Features
- Input form for three entities.
- Fetches data from the Tavily API.
- Displays comparison results in a responsive table.
- Handles loading and error states.
- Unit tests for the API logic.
Prerequisites
- Node.js (v18 or newer)
- npm or yarn
Setup
-
Clone the repository
git clone https://git.brojs.ru/kuzakhmetovartur/povtornyy-ekzamen-2-sravnitelnyy-obzor-3.git cd povtornyy-ekzamen-2-sravnitelnyy-obzor-3 -
Install dependencies
npm install # or yarn install -
Configure environment variables
Copy the example file and set your Tavily API key:
cp .env.example .envEdit
.envand replaceyour_api_key_herewith your actual key. -
Run the development server
npm run dev # or yarn devOpen http://localhost:5173 to view the app.
Testing
Run unit tests with:
npm test
# or
yarn test
Build for Production
npm run build
# or
yarn build
The production build will be in the dist folder.
Deployment
You can deploy the dist folder to any static hosting provider (Netlify, Vercel, GitHub Pages, etc.). Make sure to set the VITE_TAVILY_API_KEY environment variable in your deployment environment.
License
MIT License
Description
Languages
JavaScript
50.2%
Python
46.2%
CSS
2.8%
HTML
0.8%