Skip to content

rickgbw/cordova-plugin-safearea

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cordova-plugin-safearea

A cordova plugin to get the size of iPhone X safe area.

Installation

cordova plugin add cordova-plugin-safearea

Supported Platforms

  • iOS

Usage

document.addEventListener("deviceready", onDeviceReady, false);

function onDeviceReady() {
  window.plugins.safearea.get(successCallback, errorCallback);
}

function successCallback(result) {
  console.log(result);
}

The plugin returns a JSON object with the screen sizes.

Android Platform Quirks

Return values:

  • top <Number> − safe area top in pixels
  • bottom <Number> − safe area bottom in pixels

LICENSE

cordova-plugin-safearea is licensed under the MIT Open Source license. For more information, see the LICENSE file in this repository.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published