HTML5 introduced a standard file API. Does GHCJS give access to that? Can I use the standard Haskell IO facilities in System.IO
?
I don't think it is possible to implement standard System.IO
facilities using the HTML5 file api.
Here are some things that are possible with System.IO
, but aren't possible with the HTML5 File API:
As you can see, the HTML5 file API can pretty much only be used to upload files, and not to implement standard haskell System.IO
actions. The only thing you could do is provide a way to get a Handle
by letting the user select a file, and then provide hRead
for that handle (but that's the only operation you can provide).