Skip to content

Commit

Permalink
Add sentry
Browse files Browse the repository at this point in the history
Add sentry
  • Loading branch information
BerkeAras authored Nov 28, 2021
2 parents 5c7bc10 + 659ba93 commit c18ed6d
Show file tree
Hide file tree
Showing 5 changed files with 102 additions and 2 deletions.
2 changes: 2 additions & 0 deletions DOT_ENV_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,6 @@ REACT_APP_API_URL=http://your-api-url.com
REACT_APP_LOCALE="en-US"
REACT_APP_USE_GOOGLE_ANALYTICS=true
REACT_APP_GOOGLE_ANALYTICS="UA-XXXXXXXXX-X"
REACT_APP_USE_SENTRY=true
REACT_APP_SENTRY_DSN="https://XXXXXXXXX.XXXXXXXXX.sentry.io/XXXXXXXXX"
```
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@ This is an example of how to list things you need to use the software and how to
REACT_APP_LOCALE="en-US"
REACT_APP_USE_GOOGLE_ANALYTICS=true
REACT_APP_GOOGLE_ANALYTICS="UA-XXXXXXXXX-X"
REACT_APP_USE_SENTRY=true
REACT_APP_SENTRY_DSN="https://XXXXXXXXX.XXXXXXXXX.sentry.io/XXXXXXXXX"
```

<!-- ROADMAP -->
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
{
"name": "workgroup",
"version": "0.4.1",
"version": "0.4.2",
"private": true,
"dependencies": {
"@fortawesome/fontawesome-svg-core": "^1.2.34",
"@fortawesome/free-solid-svg-icons": "^5.15.2",
"@fortawesome/react-fontawesome": "^0.1.14",
"@reach/router": "^1.3.4",
"@sentry/react": "^6.15.0",
"@sentry/tracing": "^6.15.0",
"@testing-library/jest-dom": "^5.11.6",
"@testing-library/react": "^11.2.2",
"@testing-library/user-event": "^12.6.0",
Expand Down
14 changes: 14 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
import React from 'react'
import ReactDOM from 'react-dom'
import * as Sentry from '@sentry/react'
import { Integrations } from '@sentry/tracing'
import App from './App'
import reportWebVitals from './reportWebVitals'
import 'semantic-ui-css/semantic.min.css'

if (process.env.REACT_APP_USE_SENTRY) {
Sentry.init({
dsn: process.env.REACT_APP_SENTRY_DSN,
integrations: [new Integrations.BrowserTracing()],

// Set tracesSampleRate to 1.0 to capture 100%
// of transactions for performance monitoring.
// We recommend adjusting this value in production
tracesSampleRate: 1.0,
})
}

ReactDOM.render(<App />, document.getElementById('root'))
82 changes: 81 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1940,6 +1940,81 @@
exenv "^1.2.2"
prop-types "^15.6.2"

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-6.15.0.tgz#7a1d316dd31cedee446e359a21774bf93d1e553d"
integrity sha512-ZiqfHK5DMVgDsgMTuSwxilWIqEnZzy4yuJ9Sr6Iap1yZddPSiKHYjbBieSHn57UsWHViRB3ojbwu44LfvXKJdQ==
dependencies:
"@sentry/core" "6.15.0"
"@sentry/types" "6.15.0"
"@sentry/utils" "6.15.0"
tslib "^1.9.3"

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-6.15.0.tgz#5e877042fe18452f2273247126b32e139d5f907c"
integrity sha512-mCbKyqvD1G3Re6gv6N8tRkBz84gvVWDfLtC6d1WBArIopzter6ktEbvq0cMT6EOvGI2OLXuJ6mtHA93/Q0gGpw==
dependencies:
"@sentry/hub" "6.15.0"
"@sentry/minimal" "6.15.0"
"@sentry/types" "6.15.0"
"@sentry/utils" "6.15.0"
tslib "^1.9.3"

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-6.15.0.tgz#fb8a91d12fdd2726a884374ea7242f6bbd081d69"
integrity sha512-cUbHPeG6kKpGBaEMgbTWeU03Y1Up5T3urGF+cgtrn80PmPYYSUPvVvWlZQWPb8CJZ1yQ0gySWo5RUTatBFrEHA==
dependencies:
"@sentry/types" "6.15.0"
"@sentry/utils" "6.15.0"
tslib "^1.9.3"

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-6.15.0.tgz#fcc083ba901cfe57d25303d0b5fa8cd13e164466"
integrity sha512-7RJIvZsjBa1qFUfMrAzQsWdfZT6Gm4t6ZTYfkpsXPBA35hkzglKbBrhhsUvkxGIhUGw/PiCUqxBUjcmzQP0vfg==
dependencies:
"@sentry/hub" "6.15.0"
"@sentry/types" "6.15.0"
tslib "^1.9.3"

"@sentry/react@^6.15.0":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/react/-/react-6.15.0.tgz#4a1a3f39f61c03a675b90a114ff79a9163bcbe3b"
integrity sha512-vrrFF/KtPJQ41tmDCWpaR+bN+/TqPwqncsGLfbClE2irY3x3eCJjT2qPstlB7NQ6rTYtScyekbB0fOoNkq9FFg==
dependencies:
"@sentry/browser" "6.15.0"
"@sentry/minimal" "6.15.0"
"@sentry/types" "6.15.0"
"@sentry/utils" "6.15.0"
hoist-non-react-statics "^3.3.2"
tslib "^1.9.3"

"@sentry/tracing@^6.15.0":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/tracing/-/tracing-6.15.0.tgz#5a5f08ee6b9cc1189227536fca053cd23488600d"
integrity sha512-V5unvX8qNEfdawX+m2n0jKgmH/YR2ItWZLH+3UevBTptO+xyfvRtpgGXYWUCo3iGvFgWb1C+iIC7LViR9rTvBg==
dependencies:
"@sentry/hub" "6.15.0"
"@sentry/minimal" "6.15.0"
"@sentry/types" "6.15.0"
"@sentry/utils" "6.15.0"
tslib "^1.9.3"

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-6.15.0.tgz#a2917f8aed91471bdfd6651384ffcd47b95c43ad"
integrity sha512-zBw5gPUsofXUSpS3ZAXqRNedLRBvirl3sqkj2Lez7X2EkKRgn5D8m9fQIrig/X3TsKcXUpijDW5Buk5zeCVzJA==

"@sentry/[email protected]":
version "6.15.0"
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-6.15.0.tgz#0c247cb092b1796d39c3d16d8e6977b9cdab9ca2"
integrity sha512-gnhKKyFtnNmKWjDizo7VKD0/Vx8cgW1lCusM6WI7jy2jlO3bQA0+Dzgmr4mIReZ74mq4VpOd2Vfrx7ZldW1DMw==
dependencies:
"@sentry/types" "6.15.0"
tslib "^1.9.3"

"@sinonjs/commons@^1.7.0":
version "1.8.3"
resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.8.3.tgz#3802ddd21a50a949b6721ddd72da36e67e7f1b2d"
Expand Down Expand Up @@ -4770,6 +4845,11 @@ [email protected]:
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.2.0.tgz#97e619259ada750eea3e4ea3e26bceea5424b16a"
integrity sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==

dotenv@^10.0.0:
version "10.0.0"
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-10.0.0.tgz#3d4227b8fb95f81096cdd2b66653fb2c7085ba81"
integrity sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==

duplexer@^0.1.1:
version "0.1.2"
resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.2.tgz#3abe43aef3835f8ae077d136ddce0f276b0400e6"
Expand Down Expand Up @@ -6098,7 +6178,7 @@ hmac-drbg@^1.0.1:
minimalistic-assert "^1.0.0"
minimalistic-crypto-utils "^1.0.1"

hoist-non-react-statics@^3.0.0, hoist-non-react-statics@^3.1.0:
hoist-non-react-statics@^3.0.0, hoist-non-react-statics@^3.1.0, hoist-non-react-statics@^3.3.2:
version "3.3.2"
resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45"
integrity sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==
Expand Down

0 comments on commit c18ed6d

Please sign in to comment.