Skip to content

Commit f5dfc0a

Browse files
committed
Doc: small fixes
1 parent d2e7b5c commit f5dfc0a

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

manual/bindings.wiki

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,8 @@ class type my_js_type = object
8080
(* read only property, read value with t##.prop1 *)
8181
method prop1 : int readonly_prop
8282
83-
(* write only property, write value with t##.prop2 := 3.14 *)
84-
method prop2 : float writeonly_prop
83+
(* write only property, write value with t##.prop2 := float 3.14 *)
84+
method prop2 : number t writeonly_prop
8585
8686
(* both read and write *)
8787
method prop3 : int prop

manual/library.wiki

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ provided.
1010

1111
|= OCaml values |= Ocaml type of Javascript values |= Actual Javascript type |
1212
| {{{int}}} | {{{int}}} | Number |
13-
| {{{float}}} | {{{float}}} | Number |
13+
| {{{float}}} | {{{Js.number Js.t}}} | Number |
1414
| {{{bool}}} | {{{bool Js.t}}} | Boolean |
1515
| {{{string}}} | {{{Js.js_string Js.t}}} | String |
1616
| {{{array}}} | {{{Js.js_array Js.t}}} | Array |
@@ -45,11 +45,11 @@ instance, these three types correspond to the same Javascript method
4545
{{{drawImage}}}:
4646
{{{
4747
drawImage :
48-
imageElement t -> float -> float -> unit meth
48+
imageElement t -> number t -> number t -> unit meth
4949
drawImage_withSize :
50-
imageElement t -> float -> float -> float -> float -> unit meth
50+
imageElement t -> number t -> number t -> number t -> number t -> unit meth
5151
drawImage_fromCanvas :
52-
canvasElement t -> float -> float -> unit meth
52+
canvasElement t -> number t -> number t -> unit meth
5353
}}}
5454
This trick can also be used to refer to Javascript fields {{{type}}} or
5555
{{{Uppercase}}}, for instance as {{{_type}}} and {{{_Uppercase}}}.

0 commit comments

Comments
 (0)