From 894d1641915c4dead6656dc4e874a0b6b014addf Mon Sep 17 00:00:00 2001 From: Nikita Matrosov Date: Thu, 19 Jan 2017 16:11:15 +0300 Subject: [PATCH] CB-12369: Add plugin typings from DefinitelyTyped This closes #123 --- package.json | 1 + types/index.d.ts | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 types/index.d.ts diff --git a/package.json b/package.json index 9df051f..943b53b 100644 --- a/package.json +++ b/package.json @@ -2,6 +2,7 @@ "name": "cordova-plugin-splashscreen", "version": "4.0.2-dev", "description": "Cordova Splashscreen Plugin", + "types": "./types/index.d.ts", "cordova": { "id": "cordova-plugin-splashscreen", "platforms": [ diff --git a/types/index.d.ts b/types/index.d.ts new file mode 100644 index 0000000..968b340 --- /dev/null +++ b/types/index.d.ts @@ -0,0 +1,17 @@ +// Type definitions for Apache Cordova Splashscreen plugin +// Project: https://github.com/apache/cordova-plugin-splashscreen +// Definitions by: Microsoft Open Technologies Inc +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped +// +// Copyright (c) Microsoft Open Technologies Inc +// Licensed under the MIT license. + +interface Navigator { + /** This plugin displays and hides a splash screen during application launch. */ + splashscreen: { + /** Dismiss the splash screen. */ + hide(): void; + /** Displays the splash screen. */ + show(): void; + } +} \ No newline at end of file