Skip to content

Instantly share code, notes, and snippets.

@Deftwun
Created September 25, 2015 03:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Deftwun/b896dc81c6f453ad66fe to your computer and use it in GitHub Desktop.
Save Deftwun/b896dc81c6f453ad66fe to your computer and use it in GitHub Desktop.
/*Does not work as is just the basic idea*/
var fs; //chrome.syncFileSystem.requestFileSystem();
var reader = new FileReader();
var file,data;
fs.root.getFile("somefile.txt",{},function(a){file = a;});
reader.onloadend = function(){data=this.result;};
file.file(function(f){reader.readAsText(f);});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment