package js_of_ocaml-compiler

  1. Overview
  2. Docs
type fragment_ = {
  1. provides : (Parse_info.t option * string * Primitive.kind * Primitive.kind_arg list option) option;
  2. requires : string list;
  3. version_constraint : ((int -> int -> bool) * string) list list;
  4. weakdef : bool;
  5. always : bool;
  6. code : Javascript.program;
  7. ignore : [ `No | `Because of Primitive.condition ];
}
type fragment = [
  1. | `Always_include of Javascript.program
  2. | `Some of fragment_
]
val parse_file : string -> fragment list
val parse_string : string -> fragment list
val parse_builtin : Builtins.File.t -> fragment list
val load_files : string list -> unit
val load_fragment : filename:string -> fragment -> unit
type state
type always_required = {
  1. filename : string;
  2. program : Javascript.program;
  3. requires : string list;
}
type output = {
  1. runtime_code : Javascript.program;
  2. always_required_codes : always_required list;
}
val init : unit -> state
val resolve_deps : ?linkall:bool -> state -> Stdlib.StringSet.t -> state * Stdlib.StringSet.t
val get_provided : unit -> Stdlib.StringSet.t
val all : state -> string list
val origin : name:string -> string option
OCaml

Innovation. Community. Security.