Skip to content

Commit

Permalink
Remove be careful
Browse files Browse the repository at this point in the history
  • Loading branch information
dannywillems committed May 26, 2016
1 parent bb733b3 commit a9dc001
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,22 +65,3 @@ cordova plugin add https://github.com/mobimentum/phonegap-plugin-loading-spinner

See the official documentation
[cordova-plugin-loading-spinner](https://github.com/mobimentum/phonegap-plugin-loading-spinner)

## ! BE CAREFUL !

The device plugin creates a new object called *window.spinnerplugin*, but the object is
available when the *deviceready* event is handled.

Instead, we provide a function *Cordova_loading_spinner.t* of type unit ->
Cordova_loading_spinner.loading_spinner which does the binding when you call it.
So, use (with js_of_ocaml)

```OCaml
let on_device_ready _ =
let l = Cordova_loading_spinner.t () in
(* Some code *)
let _ =
Dom.addEventListener Dom_html.document (Dom.Event.make "deviceready")
(Dom_html.handler on_device_ready) Js._false
```

0 comments on commit a9dc001

Please sign in to comment.