0.0.10 • Published 3 years ago

koa-services v0.0.10

Weekly downloads
20
License
-
Repository
-
Last release
3 years ago

KoaServices

This library is a api helper for my Koa backend server inclugind user models, api services, and rjx stores

Installation

Run npm i koa-services to install the module in your project. Then include following lines in your app.module.ts file :

import { StoreModule, MetaReducer, ActionReducer } from '@ngrx/store';
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
import { EffectsModule } from '@ngrx/effects';
import { 
  KoaServicesModule, 
  metaReducers, reducers, UserEffects, UsersEffects,
  serverAddress, serverProtocol, SERVER_ADDRESS, SERVER_PROTOCOL } from 'koa-services';

@NgModule({
  (..)
  imports: [
    (..)
    StoreModule.forRoot(reducers, { metaReducers }),
    StoreDevtoolsModule.instrument({ logOnly: true, maxAge: false, name: 'Koa front app' }),
    EffectsModule.forRoot([UserEffects, UsersEffects]),
  ],
  providers: [
    { provide: SERVER_ADDRESS,  useValue: serverAddress},
    { provide: SERVER_PROTOCOL, useValue: serverProtocol}
  ]
  (..)
export class AppModule { }

Usage

n/a yet

Development & publishing

development phase :

$ ng build koa-services --watch --prod

production build & NPM publishing (update version in package.json):

$ ng build koa-services --prod
$ cd dist/koa-services/ $ npm publish

0.0.10

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.3

3 years ago

0.0.4

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago