Socket
Socket
Sign inDemoInstall

nativescript-sdk-utility

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nativescript-sdk-utility

This plugin is a collection of utilities for iOS and Android to simplify your NativeScript apps.


Version published
Weekly downloads
1
decreased by-91.67%
Maintainers
1
Weekly downloads
 
Created
Source

NativeScript SDK Utility

This plugin provides device specific functions that simplify your NativeScript apps.

  • getVersion(): Returns the current version of your app.
  • is24HFormat(): Returns a boolean value that indicates if the device is using a 24H time format.

Installation

tns plugin add nativescript-sdk-utility

Usage

```JavaScript
var sdk = require('nativescript-sdk-utility');

var version = sdk.getVersion();
var is24H = sdk.is24HFormat();
```)

```TypeScript
var sdk = require('nativescript-sdk-utility');

var version: string = sdk.getVersion();
var is24H: boolean = sdk.is24HFormat();
```)

```TypeScript (alternative)
import { SDKUtility } from 'nativescript-sdk-utility';

export class MyModel {
    public version: string;
    public is24H: boolean;

    private sdk: SDKUtility;

    constructor() {
        super();

        this.sdk = new SDKUtility();
        this.version = this.sdk.getVersion();
        this.is24H = this.sdk.is24HFormat();
    }
}
```

License

Apache License Version 2.0, January 2004

Keywords

FAQs

Package last updated on 17 Apr 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc