My Weather app
Introduction
This article is about my experience or learnings creating a weather app / website. I used html, css, javascript to create this website I also used a module bundler called webpack to bring all my code into a more structured format.
what I learned
Asynchronous programming - javascript is a single threaded programming language which excutes the code in a synchronous manner going line by line and task by task. this can cause delay in loading certain components of website asynchronous programming lets us run those operations in the background or queue them until callstack is free.
callbacks - this are functions that call another functions.
promises - this are asynchronous object for handling tasks by resolving the on success and rejecting the on failure.
fetch - this is used to pull up some data from the internet for example an image an use it inside our code. fetch returns a response promise which is required to parsed as json objects
async / await - this are syntactic sugars for writing the asynchronous code in a synchronous manner