cordova-plugin-smartlook
TypeScript icon, indicating that this package has built-in type declarations

2.0.3 • Public • Published

Smartlook Cordova SDK

Official Smartlook SDK plugin for Cordova Android & iOS applications.

Minimum supported versions

The minimum supported Android version is Jelly Bean (API 18)

The minimum supported iOS version is 13

The minimum supported Cordova CLI version is 10.0.0

The minimum supported Cordova Android engine is 10.1.1

Integration

  1. Add the Cordova plugin to your project:
npm install cordova-plugin-smartlook

or

cordova plugin add cordova-plugin-smartlook
  1. Setup and start Smartlook using the deviceready callback:
if(document.readyState === "complete") {
  document.addEventListener("deviceready", onDeviceReady, false);
}

function onDeviceReady() {
  	Smartlook.setProjectKey({key: "YOUR_API_KEY"});
  	Smartlook.start();
}

Project API Key

To setup Smartlook, you need your project API key. You can find your project key in the mobile project settings in the Smartlook app.

  1. If you cannot access TypeScript types, you need to explicitly set the type folder roots. Add the following to your project's tsconfig.json:
"typeRoots": ["./node_modules/@types", "./node_modules/cordova-plugin-smartlook/globalTypes"]

Package Sidebar

Install

npm i cordova-plugin-smartlook

Weekly Downloads

1,720

Version

2.0.3

License

MIT

Unpacked Size

43.4 MB

Total Files

49

Last publish

Collaborators

  • smartlook.npm
  • c0mtru1se
  • samialdury
  • jakubpetriska
  • pjk
  • amertak
  • acro
  • janzal
  • millcek
  • joozty
  • klobinoid
  • frantisekspurny