@mycure/sdk
TypeScript icon, indicating that this package has built-in type declarations

5.9.2 • Public • Published

Mycure sdk-web

Installation and Usage

$ yarn add firebase socket.io-client @mycure/sdk
import sdk from '@mycure/sdk';
import socket from 'socket.io-client';
// import { connect as socket } from 'nativescript-socketio'; // for nativescript
import firebase from 'firebase';

// initialize the sdk
sdk.initilize('http://mcv4.herokuapp.com', {
  socket,
  firebaseApp: firebase.initializeApp({ // <-- pass already initialized firebaseApp
    // ...config here
  })
});

// observe the current user
sdk.auth().currentUser$.subscribe(console.log);

// signin
await sdk.auth().signin('local', { email: 'test@mycure.md', password: 'password' })

Versions

Current Tags

Version History

Package Sidebar

Install

npm i @mycure/sdk

Weekly Downloads

40

Version

5.9.2

License

MIT

Unpacked Size

244 kB

Total Files

171

Last publish

Collaborators

  • cent1pede
  • metsys