Log Mobx Actions, Reactions, Transactions and Computations
JavaScript
Latest commit e3726ea Jan 19, 2017 @winterbe 2017
Permalink
Failed to load latest commit information.
docs Add screenshot Aug 23, 2016
src Migrate to Mobx 3 Jan 19, 2017
.babelrc Awake project Aug 23, 2016
.gitignore Fix umd build Aug 23, 2016
LICENSE 2017 Jan 19, 2017
README.md Replace npmcdn.com with unpkg.com Sep 1, 2016
package.json Migrate to Mobx 3 Jan 19, 2017
webpack.config.js Fix umd build Aug 23, 2016

README.md

MobX Logger

Always know what is really going on in your MobX application by logging just the right information.

mobx-logger

Follow on Twitter for Updates

Install

NPM: npm install mobx-logger

CDN: https://unpkg.com/mobx-logger/mobx-logger.umd.js

Usage

import {enableLogging} from 'mobx-logger';

// optional
const config = {...};

enableLogging(config);

Options

Unlike MobX DevTools you can simply configure which particular information should be logged to the console. Currently Actions, Reactions, Transactions and Computations are supported.

{
    predicate: () => true|false,
    action: true|false,
    reaction: true|false,
    transaction: true|false,
    compute: true|false
}

ReactNative

For ReactNative development use this predicate to only enable logging in dev mode with JS debugging enabled:

enableLogging({
    predicate: () => __DEV__ && Boolean(window.navigator.userAgent),
    ...
});

License

MIT