Follow on Twitter for Updates
NPM: npm install mobx-logger
CDN: https://npmcdn.com/mobx-logger/mobx-logger.umd.js
import {enableLogging} from 'mobx-logger';
// optional
const config = {...};
enableLogging(config);
{
predicate: () => true|false,
action: true|false,
reaction: true|false,
transaction: true|false,
compute: true|false
}
For ReactNative development use this predicate to only enable logging in dev mode with JS debugging enabled:
enableLogging({
predicate: () => __DEV__ && Boolean(window.navigator.userAgent),
...
});
MIT