0.1.4 • Published 7 years ago

elastic-store-logger v0.1.4

Weekly downloads
1
License
ISC
Repository
github
Last release
7 years ago

Introduction

A logger for elastic-store.

Installation

$ npm install --save elastic-store-logger

Usage

It can be attached in two different ways.

While creating a store

import {Store} from "elastic-store";
import {logger} from "elastic-store-logger";

let actions = { ... };

let aStore = Store(actions, [logger]);

After creating a store

import {Store} from "elastic-store";
import {logger} from "elastic-store-logger";

let actions = {
	todos: {
		add () { ... },
		remove () { ... }
	},
	notification: { ... }
};

let aStore = Store(actions);

// will log changes made by actions at 'todos' node
aStore.attach("todos", logger);

// OR

// will log changes caused by action at 'todos.add'
aStore.attach("todos.add", logger);
0.1.4

7 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago