Fmlib_js.File_readerThe javascript file reader object
val event_target : t -> Event_target.tView the file reader as an event target.
For reading the contents of a file into memory, an event handler for the loadend event has to be registered and a read function, e.g. read_text has to be called. The handler can then obtain the file contents by calling result and decode them using one of the following decoders:
Base.Decode.string, if read_text was usedval make : unit -> tCreate a file reader.
val ready_state : t -> intReady state of the read operation.
0: empty
1: loading
2: doneval result : t -> Base.Value.t optionThe result of the read operation or None if an error occurred.