captbaritone / raven-for-redux

A Raven middleware for Redux

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for @sentry/browser

deammer opened this issue · comments

Hi, I'm trying to set up raven-for-redux with @sentry/browser but can't find a way to set up the middleware. The init method adds a window.__SENTRY__ object but it doesn't have the necessary setDataCallback hook. Here's my setup:

import thunk from 'redux-thunk';
import { applyMiddleware, createStore, compose } from 'redux';
import { init } from '@sentry/browser';
import createRavenMiddleware from 'raven-for-redux';

// Init Sentry
init({
  dsn: process.env.SENTRY_URL,
  environment: process.env.NODE_ENV
});

// Create the store
const reduxStore = createStore(
  rootReducer,
  compose(applyMiddleware(thunk, createRavenMiddleware(window.__SENTRY__)))
);

Any ideas?

I apologize, this is a duplicate of #82.