You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Lorin Beer (JIRA)" <ji...@apache.org> on 2014/08/14 21:48:18 UTC

[jira] [Created] (CB-7313) Misleading documentation in Device Motion Plugin

Lorin Beer created CB-7313:
------------------------------

             Summary: Misleading documentation in Device Motion Plugin
                 Key: CB-7313
                 URL: https://issues.apache.org/jira/browse/CB-7313
             Project: Apache Cordova
          Issue Type: Bug
          Components: Plugin Device Motion
            Reporter: Lorin Beer
            Assignee: Lorin Beer
            Priority: Minor


device motion documentation reads

```
The returned watch ID references the accelerometer's watch interval, and can be used with navigator.accelerometer.clearWatch to stop watching the accelerometer.

var watchID = navigator.accelerometer.watchAcceleration(accelerometerSuccess,
                                                       accelerometerError,
                                                       [accelerometerOptions]);
```

last line indicates an array is the expected argument, which causes the api to return an error

it should read

```
accelerometerOptions

the rest of watchAccel correctly documents accelerometerOptions as an object.



--
This message was sent by Atlassian JIRA
(v6.2#6252)