Creating a weather app inspired by this tutorial from Jonah Lawrence.
This has been my first time using Typescript and using a local server to build using Typescript.
I'm incorporating the OpenWeather, Google Maps and Unsplash APIs.
- Initiated
NPM - Added
prettier,typescriptandtsc-watchas dev dependencies - added
gitand.gitignore - created
/build, /src, /publicstructure and addedpackage.jsonwithnpm run test, buildscripts that output to/public, /buildor run tests without emitting files. - Configured ./vscode with
launch.jsonandtasks.jsonto activate debug functionality within VSC. This was hard!
- In your CLI, run:
npm init -y - To build, run:
npm run build - To automatically compile based on changes in Typescript (stored in ./src/scripts) and HTML & CSS (stored in ./public/*) use:
npm run watch-tsnpm run watch-public
- Run a Live Server on
./build/index.html
-
Get Unsplash image URL to insert in the right element so that the other elements remain visible.
-
Make search query also update the Unsplash API call.
-
Update city text based on API data rather than search query.
-
Limit the search to only searchable cities.
-
Add drop-down to search field to ensure that only cities are selected.
-
Made dropdown selectable by clicking and pressing enter.
-
Move API key to separate file that's included in
.gitignore -
Reset API keys that I'd previously publicized
-
Add serverless API for all possible API calls and test them rigorously.
- Update temperature on homepage
- When no image is loaded, there shouldn't be any link on the background image.
- Avoid double-call of search query when selecting city from Google Maps API instead of typing.
- Solve
callbackcomplaint of Google Maps API without integrating a map on the site.