mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-02-07 23:03:19 +08:00
docs(plugin): add docs
This commit is contained in:
parent
8855359527
commit
e053c945ee
@ -47,7 +47,20 @@ export interface CompassOptions {
|
|||||||
* ````
|
* ````
|
||||||
*
|
*
|
||||||
* @usage
|
* @usage
|
||||||
* ```js
|
* ```ts
|
||||||
|
* // Get the device current compass heading
|
||||||
|
* DeviceOrientation.getCurrentHeading().then(
|
||||||
|
* data => console.log(data),
|
||||||
|
* error => console.log(error)
|
||||||
|
* );
|
||||||
|
*
|
||||||
|
* // Watch the device compass heading change
|
||||||
|
* var subscription = DeviceOrientation.watchHeading().subscribe(
|
||||||
|
* data => console.log(data)
|
||||||
|
* );
|
||||||
|
*
|
||||||
|
* // Stop watching heading change
|
||||||
|
* subscription.unsubscribe();
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
@Plugin({
|
@Plugin({
|
||||||
|
Loading…
Reference in New Issue
Block a user