9. Code review
9.1 Removing empty paintings
In our renderPaintings function we’ll check for each painting if the imgPath is known, if not the painting will be set to display=none. We have to set the other paintings back to display=block:
9.2 Showing painting loader spinner
Add class ‘loading’ to each image in the index.html and we will add a background to this image, so the user will see the loading spinner untill the image is ready and will overlay the background.
9.3 Showing loading spinner on startup
For this we will add an overlay div on top of everything else, and remove the overlay when the window has loaded fully.
At the end of our index file we add:
Let’s deploy our app to an AWS server with continuous deployment. Meaning every time we commit to our github repository, our live app gets updated as well.
10.1 AWS Amplify
AWS amplify makes sure every time you’ll commit to you github repository, the webapp get updated. THis is called continuous deployment.
Upload all the contents from your /dist folder to your FTP and you are done!