@kemtai/web-sdk
v2.0.4
Published
Kemtai Web SDK
Downloads
580
Readme
Official Web SDK for Kemtai
Overview
Kemtai Web SDK is a Javascript library built with typescript to make it easier to embed Kemtai's UI components.
Before you start
This SDK is intended to be used in an existing projects that use Kemtai's API.
Installation
yarn add @kemtai/web-sdk
# or
npm i @kemtai/web-sdk
Usage
<!DOCTYPE html>
<html>
<head>
<script type="module">
import { Kemtai, PatientProtocolEmbeddable } from '@kemtai/web-sdk';
const kemtaiToken = ""; // Obtain during the auth flow
// Should await for init before rendering the iframe
await Kemtai.init({
token: kemtaiToken
});
const embeddable = new PatientProtocolEmbeddable({
containerId: "kemtaiEmbeddable",
patientId: "",
height: "100%",
width: "100%"
});
</script>
</head>
<body>
<div id="kemtaiEmbeddable"></div>
</body>
</html>