0.0.9 • Published 2 years ago

trakiframetest v0.0.9

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

Trak Iframe

About The Project

Trak Iframe focusing to embeded authorised way of showing websites inside a Iframe.

Getting Started

Trak Iframe

Installation

_Below is an example of how we can add trak iframe into your project.

  1. Install Trak Iframe Package

    Using Npm

        npm install trakiframe

    Using Yarn

        yarn add trakiframe
  2. Import Trak Iframe
         const TrakComponent = require('trakiframe');
    or
      import * as Trak from 'trakiframe';
  3. Initialize Trak Iframe with Token using init method
     TrakComponent.init({
         token: 'Token',
     })
    using init method with publickey and token
     TrakComponent.init({
         token: 'Token',
         publicKey: <---key---->
     })
    or using init method encrypting using package function
     TrakComponent.init({
         token: TrakComponent.encrypt(token),
     })
  4. Load iframe using show method eg: button Click
        TrakComponent.show({...});
         const mountComponent = () => {
             TrakComponent.show({
                 'physiotherapist_name': 'fer',
                 'patient_name': 'qqqq',
                 'component': 'metrics',
             })
         }
         <button onClick={mountComponent}>Click</button>
  5. Remove iframe using remove method
        TrakComponent.remove();

In Angular style fix

Import styles from package to app

1.in Angular.json file projects -> demo -> architect -> build -> options -> styles

add
```json 
    "./node_modules/trakiframe/trakStyle.css"
```

License

Distributed under the MIT License. See LICENSE.txt for more information.

0.0.9

2 years ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago