import { actionLogger } from '../utils/action-logger' ; import type { Middleware } from './model' ; /**
 * Log all actions to console
 */ export const logMiddleware = ( ) : Middleware => ( ) => ( next ) => ( action ) => { if ( process . env . NODE_ENV === 'development' ) { actionLogger ( action ) ; } return next ( action ) ; } ;