This project is a weather application built with Next.js and TypeScript. It allows users to search for a city's weather, view the current weather, a five-day forecast, and the daily evolution of temperatures. The application integrates with the AccuWeather API for retrieving weather data.
- Search for a city's weather using the AccuWeather API.
- View current weather conditions.
- See a five-day weather forecast.
- Toggle between Celsius and Fahrenheit for temperature.
- View the daily temperature evolution chart.
- Responsive design with mobile-first approach.
- Storybook integration for component visualization.
- Unit tests with Jest and React Testing Library.
Before you begin, ensure you have the following installed on your machine:
- An AccuWeather API key
- Node.js (>= 14.0.0)
- npm (>= 6.0.0) or yarn (>= 1.22.18)
- Clone the repository:
git clone https://github.com/sinafbd/clique-digital-interview-next
cd clique-digital-interview-next
-
rename the
.env.example
to.env.local
-
yarn dev
yarn storybook
yarn test
NEXT_PUBLIC_ACCUWEATHER_API_KEY=YOUR_ACCUWEATHER_API_KEY (or rename the .env.example
to .env.local
)
NEXT_PUBLIC_ACCUWEATHER_BASE_URL=http://dataservice.accuweather.com