Module Js

module Js: sig .. end
The Entry point to the JavaScript API

This module will be exported



type (-'obj, +'a) meth_callback 
internal types for FFI, these types are not used by normal users
type (-'arg, +'result) meth 
itnernal
type (-'arg, +'result) fn 
Js uncurried function
type +'a t 
Types for JS objects

Js object type

type +'a null 
nullable, value of this type can be either null or 'a this type is the same as Js.Null.t
type +'a undefined 
value of this type can be either undefined or 'a this type is the same as Js.Undefined.t
type +'a null_undefined 
value of this type can be undefined, null or 'a this type is the same as Js.Null_undefined.t
type boolean 
The JS boolean type, can be Js.true_ or Js.false_
type (+'a, +'e) promise 
The promise type, defined here for interop
val true_ : boolean
val false_ : boolean
val null : 'a null
val undefined : 'a undefined
val to_bool : boolean -> bool
convert Js boolean to OCaml bool
val typeof : 'a -> string
typeof x will be compiled as typeof x in JS
val log : 'a -> unit
A convenience function to log
val unsafe_lt : 'a -> 'a -> bool
unsafe_lt a b will be compiled as a < b
val unsafe_le : 'a -> 'a -> bool
unsafe_le a b will be compiled as a <= b
val unsafe_gt : 'a -> 'a -> bool
unsafe_gt a b will be compiled as a > b
val unsafe_ge : 'a -> 'a -> bool
unsafe_ge a b will be compiled as a >= b
module Null: Js_null
module Undefined: Js_undefined
module Null_undefined: Js_null_undefined
module Array: Js_array
module Boolean: Js_boolean
module Date: Js_date
module Dict: Js_dict
module Global: Js_global
module Json: Js_json
module Math: Js_math
module Obj: Js_obj
module Re: Js_re
module String: Js_string
module Typed_array: Js_typed_array
module Types: Js_types
module Float: Js_float
module Int: Js_int