SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.
TypeScript apmapplication-monitoringdistributed-tracinggogood-first-issuejaegerloglogsmetricsmonitoringnextjsobservabilityopen-sourceopentelemetryprometheusreactreactjsself-hostedtracingtypescript
// eslint-disable-next-line no-restricted-imports
import {
applyMiddleware,
legacy_createStore as createStore,
Store,
} from 'redux';
import thunk from 'redux-thunk';
import reducers, { AppState } from 'store/reducers';
/**
* A fresh store per story, seeded with the real reducers so dispatches keep
* working, unlike the mock store used in jest. Nothing leaks between stories.
* The modules that read the redux singleton directly are pointed at it too,
* through `mocks/store.mock.ts`.
*/
export const createStorybookStore = (reduxState?: Partial<AppState>): Store =>
createStore(
reducers,
reduxState as ReturnType<typeof reducers> | undefined,
applyMiddleware(thunk),
);