@bradtech/types

1.0.1 • Public • Published

Brad Technology / Types

Shared types package for Brad apps

Usage

import {
  User,
  Payload,
  Auth,
  Location,
  Subscription,
  Reference,
} from "@bradtech/types";

const fakePayload: Payload<void> = {
  status: 200,
  message: "ok",
};

const fakeUser: User = {
  uid: "6R789IOHJ",
  email: "sisi@gmail.com",
  firstname: "Max",
  lastname: "Ime",
};

const fakeAuth: Auth = {
  uid: "localId",
  idToken: "idToken",
  refreshToken: "refreshToken",
  expiresIn: 3600,
};

const fakeSub: Subscription = {
  id: "12345",
  createdAt: 23456789,
  startAt: 23456789,
  endAt: 23456789,
  status: "actif",
  name: "random name",
  company: {
    ref: "company/fdsdfs",
    label: "label",
  },
};

const fakeLoc: Location = {
  id: "123",
  position: [43.555806808, 4.4918886346],
  startAt: 123435232,
  status: "actif",
};

const fakeRef: Reference = {
  ref: "company/fdsdfs",
  label: "label",
};

Test

yarn test

Readme

Keywords

none

Package Sidebar

Install

npm i @bradtech/types

Weekly Downloads

1

Version

1.0.1

License

AGPL-3.0-or-later

Unpacked Size

3.44 kB

Total Files

13

Last publish

Collaborators

  • elliottlepine
  • crapougnax