@musora/services

0.1.4 • Public • Published

js-services - @musora/services

HTTP request modules for all Musora back-end services

Build Status Coverage Status

Installation

Yarn

yard add @musora/services

NPM

npm install @musora/services --save

Usage

Configure the Instance

When your app starts up, you can call the configue method below to configure your current request instance with some defaults, like the base url and the users authentication token.

import { configure } from '@musora/services';

configure({
    baseUrl: 'https://drumeo.com/laravel/public',
    contentType: 'application/json',
    accept: 'application/json',
    authToken: '...'
});

Entire Module

import Services from '@musora/services';

Services.Railcontent.getContent(...);

Individual Module

import { Railcontent } from '@musora/services';

Railcontent.getContent(...);

Individual Function

import { getContent } from '@musora/services';

getContent(...);

Local Development

  • yarn test - Run all tests
  • yarn docs - Auto generate documentation

Readme

Keywords

none

Package Sidebar

Install

npm i @musora/services

Weekly Downloads

1

Version

0.1.4

License

MIT

Unpacked Size

227 kB

Total Files

319

Last publish

Collaborators

  • musora_dev
  • kp-98
  • magnito