Local file reader
Since HTML5 we can finally interact with local files using the JavaScript that runs in our browser, which is really an amazing feature. Using this feature, we can upload files from our device to our web app and read from them in our app. This means that we can attach files to forms for example, which is great in many cases whenever we need to upload some sort of file for whatever purpose, for example, adding a résumé to your online job application.
Let's first make sure that the browser you are using supports this. We can run a simple script to check whether it does:
<!DOCTYPE html>
<html>
<body>
<div id="message"></div>
<script>
let message = document.getElementById("message");
if (window.FileReader) {
message.innerText = "Good to go!";
} else {
message.innerText = "No FileReader :(";
}
</script>
</body...