docs(): add example on how to use onChange() method (#1726)

This commit is contained in:
Thomas 2017-07-03 14:29:52 -07:00 committed by Ibby Hadeed
parent f289a6bbb6
commit 3af23023ee

View File

@ -26,8 +26,16 @@ import { Observable } from 'rxjs/Observable';
*
* // allow user rotate
* this.screenOrientation.unlock();
* ```
*
* // detect orientation changes
* this.screenOrientation.onChange().subscribe(
* () => {
* console.log("Orientation Changed");
* }
* );
*
* ```
*
* @advanced
*
* Accepted orientation values: