userpilot
TypeScript icon, indicating that this package has built-in type declarations

1.3.6 • Public • Published

How to use

Initialize

In your module.ts file import userpilot and initialize with your app token

import { Userpilot } from 'userpilot'
Userpilot.initialize('< your app token >');

Identify User

// .....

import { Userpilot } from 'userpilot'

// .....

@Component({
  selector: 'app-login',
  templateUrl: './login.component.html',
  styleUrls: ['./login.component.scss']
})
export class LoginComponent implements OnInit {

  // .....

  login() {
    this.loginService.login(this.form.value).then((user) => {

      Userpilot.identify(user.id, {name: user.firstName, email: user.email,created_at: user.signedUp});

      // ....

    }).catch((err) => {

    });
  }

}

For more information about Userpilot API please visit https://docs.userpilot.com/article/61-javascript-api

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
1.3.612,166latest

Version History

VersionDownloads (Last 7 Days)Published
1.3.612,166
1.3.518,126
1.3.41
1.3.3622
1.3.24,810
1.3.15,908
1.3.01,312
1.2.93,488
1.2.820,774
1.2.767
1.2.60
1.2.51,049
1.2.499
1.2.3205
1.2.20
1.2.10
1.2.00
1.1.97
1.1.80
1.1.715
1.1.60
1.1.50
1.1.40
1.1.312
1.1.20
1.1.10
1.1.00
1.0.90
1.0.817
1.0.70
1.0.60
1.0.50
1.0.40
1.0.30
1.0.20
1.0.10
1.0.00

Package Sidebar

Install

npm i userpilot

Weekly Downloads

68,678

Version

1.3.6

License

MIT

Unpacked Size

12.1 kB

Total Files

6

Last publish

Collaborators

  • karmiatuserpilot
  • samerfawadleh-u
  • majd_sehwail
  • subscriptions
  • thabet-userpilot