Weather app using openweather
, openstreetmap
, leaflet
and pelias.smappen.com
APIs
To configure the project, please add your openweather API KEY in the .env
or .env.local
file.
Note :
I didn’t have access to the paid part of the OpenWeather API, so I couldn’t retrieve the forecast for the coming days.
Therefore, the dedicated block in the application uses a calculation to determine the minimum and maximum temperatures for each day via the endpoint: https://api.openweathermap.org/data/2.5/forecast.
Calculation method:
useCityStore:forecastDaysWithIconListReducerCb
VSCode + Volar (and disable Vetur).
TypeScript cannot handle type information for .vue
imports by default, so we replace the tsc
CLI with vue-tsc
for type checking. In editors, we need Volar to make the TypeScript language service aware of .vue
types.
See Vite Configuration Reference.
pnpm install
pnpm dev
pnpm build
Run Unit Tests with Vitest
pnpm test:unit
Lint with ESLint
pnpm lint