0.1.4 • Published 5 years ago

@dxd_sjtu/call-client v0.1.4

Weekly downloads
-
License
ISC
Repository
github
Last release
5 years ago

@dxd_sjtu/call-client

NPM version npm download

中文版文档

What is it:

This is a lib to call a app in h5 env.

Install

$ npm install @dxd_sjtu/call-client --save
$ yarn add @dxd_sjtu/call-client

Init Args:

  • deepLink //URLSchema;
  • intentLink //intent link for android;
  • iosStore //ios's app store link for app
  • androidStore //android's app store link for app

Usage

import CallClient from '@dxd_sjtu/call-client';

const deepLink = 'userschema for your app';
const intentLink = 'intent for your android app';
const iosStore = 'https://itunes.apple.com/app/id785385147?mt=8';
const androidStore = 'https://play.google.com/store/apps/details?id=com.lazada.android';

const callClient = new CallClient(
      deepLink,
      intentLink,
      iosStore,
      androidStore
    );
callClient.callApp();

Behavior:

It will call app at first, if no app is called then it will link to your download link.

TODO:

track config
0.1.4

5 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.0

5 years ago

0.0.1

5 years ago