@sentry/react
@sentry/browser
@sentry/node
raven-js
raven-node
_(raven for node)_0.0.0
I have a simple setup to capture events to sentry, like below
// import * as Sentry from "@sentry/browser"; // same with this package
import * as Sentry from "@sentry/react";
Sentry.init({
dsn: "https://[email protected]/1319034",
release: "my-project-name@" + process.env.npm_package_version,
});
const logError = (error) => {
Sentry.captureException(error);
};
function App() {
logError(new Error("from create-react-app"));
return (
<div className="App">
<header className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<p>
Edit <code>src/App.js</code> and save to reload.
</p>
<a
className="App-link"
href="https://reactjs.org"
target="_blank"
rel="noopener noreferrer"
>
Learn React
</a>
</header>
</div>
);
}
but request to sentry ended up being 403 (forbidden) and it's because of CORS, Any one has same problem ?
Hey @karna41317 - in your Sentry account, double check these settings:
I was having this CORS error as well too and it turned out my ad blocker (uBlock Origin on Firefox OSX) was blocking connection to Sentry.
Closing the issue as a part of large repository cleanup, due to it being inactive and/or outdated.
Please do not hesitate to ping me if it is still relevant, and I will happily reopen and work on it.
Cheers!
Most helpful comment
I was having this CORS error as well too and it turned out my ad blocker (uBlock Origin on Firefox OSX) was blocking connection to Sentry.