From 3dca28fbcfe8d5d1b129173490d9451c2d1cacd2 Mon Sep 17 00:00:00 2001 From: Zalmoxisus Date: Fri, 20 May 2016 19:29:00 +0300 Subject: [PATCH] Update README --- README.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index b899b68..e05d845 100644 --- a/README.md +++ b/README.md @@ -21,14 +21,16 @@ import { createDevTools } from 'redux-devtools'; import FilterMonitor from 'redux-devtools-filter-actions'; import LogMonitor from 'redux-devtools-log-monitor'; +// Stripping big data which slows down DevTools Monitor +const actionsFilter = (action) => ( + action.type === 'FILE_DOWNLOAD_SUCCESS' && action.data ? + { ...action, data: '<>' } : action +); + export default createDevTools( ( - action.type === 'FILE_DOWNLOAD_SUCCESS' && action.data ? - { ...action, data: '<>' } : action - ) - } + actionsFilter={actionsFilter} statesFilter={(state) => state.data ? { ...state, data: '<>' } : state} >