- Objective - To create a webpage that will upload a file and print the file-content to the
console
window. - Purpose - To establish familiarity javascript's file-reader object.
- Description
- You are provided with a file located at
./assets/js/read-files.js
- Edit the file by defining the respective function-stub.
- You are provided with a file located at
- Begin by forking this project into a personal repository.
- To do this, click the
Fork
button located at the top right of this page.
- To do this, click the
- Navigate to your github profile to find the newly forked repository.
- Clone the repository from your account into the
~/dev
directory. - Open the newly cloned project in a code editor (Visual Studio Code, for example).
- Upon cloning the project, from a browser, open the
./index.html
located at the root of the project. - Upon uploading a file via the
input
web-element, the inspector tools should reveallog
messages fromconsole
displaying the respective filecontent.- Upload
./assets/file-to-upload.txt
as a way of testing your application.
- Upload
- Modify
./assets/js/read-files.js
to ensure that the output selecting a given file is the text-content of the file displayed inconsole
. - Below is an image of expected output, given the input is
./assets/file-to-upload.txt
- Upon completion, submit a pull request from your repository to this remote repository.