Module Js_of_ocaml.Sys_js
Javascript specific Sys functions.
Io.
Pseudo filesystem.
val mount_point : unit -> string list
val unmount : path:string -> unit
val mount : path:string -> (prefix:string -> path:string -> string option) -> unit
Register a callback to the
path
to dynamically load missing files. Whenever a file is missing inpath
, the callback is used to optionally get the content of the file.mount ~path f
register the callbackf
to the pathpath
. The callbackf
receives(prefix,suffix)
where:prefix
is the path the function has been registered to.Filename.contact prefix suffix
is the absolute filename .
val read_file : name:string -> string
read_file name
returns the content of the filename
. RaiseNot_found
if the file does not exists.
Information.
val js_of_ocaml_version : string
js_of_ocaml_version
is the version of Js_of_ocaml. It is a string of the form"major.minor[.patchlevel][+additional-info]"
, wheremajor
,minor
, andpatchlevel
are integers, andadditional-info
is an arbitrary string. The[.patchlevel]
and[+additional-info]
parts may be absent.