I want to be able to store the contents from an imported text file in a JS variable. Could someone please show me how I would go about doing this by using the JSFiddle example I have created? https://jsfiddle.net/495v0bxf/. Currently in the JSFiddle, you can select a document and display the contents.
I know the content can be accessed in the reader variable under 'result':
var reader = new FileReader();
console.log("reader: ", reader);
But I want the content to be stored in say:
var txtContent =