How to set orientation in nativescript
Hello I would like to know how to set device orientation in nativescript. Specifically I want the application that I am writing to stay in the same orientation (portrait) at all times so that rotating the device does not cause it to go into landscape. I tried the nativescript-orientation plugin and setOrientation. var orientation = require('nativescript-orientation'); console.log(JSON.stringify(orientation));// outputs JS: {} orientation.setOrientation("portrait"); However I get the error "Cannot read property setOrientation of undefined. tns plugin list shows that the plugin is installed.