-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
84 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -101,14 +101,15 @@ | |
"license": "MIT", | ||
"scripts": { | ||
"build": "cross-env NODE_ENV=production gatsby build", | ||
"build:ci": "cross-env NODE_ENV=production GATSBY_EXPERIMENTAL_PAGE_BUILD_ON_DATA_CHANGES=true gatsby build --log-pages --verbose", | ||
"build:ci": "cross-env NODE_ENV=production GATSBY_EXPERIMENTAL_PAGE_BUILD_ON_DATA_CHANGES=true gatsby build --log-pages --verbose && yarn run sentry:sourcemaps", | ||
"develop": "gatsby develop", | ||
"format": "prettier --write \"**/*.{js,jsx,ts,tsx,json,md,less,mdx}\"", | ||
"format:check": "prettier --check \"**/*.{js,jsx,ts,tsx,json,md,less,mdx}\"", | ||
"start": "yarn develop", | ||
"serve": "gatsby serve", | ||
"clean": "gatsby clean", | ||
"lint": "eslint . --ext md,mdx" | ||
"lint": "eslint . --ext md,mdx", | ||
"sentry:sourcemaps": "sentry-cli sourcemaps inject --org davw-network --project mastdatabase ./public && sentry-cli --url https://sentry.service.davw.network sourcemaps upload --org davw-network --project mastdatabase ./public" | ||
}, | ||
"packageManager": "[email protected]", | ||
"resolutions": { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,10 +3,66 @@ import * as Sentry from '@sentry/gatsby' | |
const __IS_DEV__ = process.env.NODE_ENV !== 'production' | ||
|
||
Sentry.init({ | ||
dsn: 'https://[email protected]/6778122', | ||
sampleRate: __IS_DEV__ ? 1.0 : 0.7, // Adjust this value in production | ||
// beforeSend(event) { | ||
// return event | ||
// }, | ||
dsn: 'https://[email protected]/3', | ||
sampleRate: 1.0, | ||
release: process.env.RELEASE, | ||
|
||
integrations: [ | ||
new Sentry.Replay({ | ||
maskAllText: false, | ||
blockAllMedia: false, | ||
}), | ||
new Sentry.BrowserTracing({ | ||
// Set 'tracePropagationTargets' to control for which URLs distributed tracing should be enabled | ||
tracePropagationTargets: ['localhost', /^https:\/\/yourserver\.io\/api/], | ||
}), | ||
], | ||
|
||
tracesSampleRate: __IS_DEV__ ? 1.0 : 0.3, | ||
replaysOnErrorSampleRate: 0.05, | ||
replaysSessionSampleRate: __IS_DEV__ ? 1.0 : 0.001, | ||
|
||
ignoreErrors: [ | ||
/minified react error/i, | ||
|
||
// See: https://docs.sentry.io/platforms/javascript/guides/gatsby/configuration/filtering/#decluttering-sentry | ||
// Random plugins/extensions | ||
'top.GLOBALS', | ||
// See: http://blog.errorception.com/2012/03/tale-of-unfindable-js-error.html | ||
'originalCreateNotification', | ||
'canvas.contentDocument', | ||
'MyApp_RemoveAllHighlights', | ||
'http://tt.epicplay.com', | ||
"Can't find variable: ZiteReader", | ||
'jigsaw is not defined', | ||
'ComboSearch is not defined', | ||
'http://loading.retry.widdit.com/', | ||
'atomicFindClose', | ||
// Facebook borked | ||
'fb_xd_fragment', | ||
// ISP "optimizing" proxy - `Cache-Control: no-transform` seems to | ||
// reduce this. (thanks @acdha) | ||
// See http://stackoverflow.com/questions/4113268 | ||
'bmi_SafeAddOnload', | ||
'EBCallBackMessageReceived', | ||
// See http://toolbar.conduit.com/Developer/HtmlAndGadget/Methods/JSInjection.aspx | ||
'conduitPage', | ||
], | ||
denyUrls: [ | ||
// Facebook flakiness | ||
/graph\.facebook\.com/i, | ||
// Facebook blocked | ||
/connect\.facebook\.net\/en_US\/all\.js/i, | ||
// Woopra flakiness | ||
/eatdifferent\.com\.woopra-ns\.com/i, | ||
/static\.woopra\.com\/js\/woopra\.js/i, | ||
// Chrome extensions | ||
/extensions\//i, | ||
/^chrome:\/\//i, | ||
/^chrome-extension:\/\//i, | ||
// Other plugins | ||
/127\.0\.0\.1:4001\/isrunning/i, // Cacaoweb | ||
/webappstoolbarba\.texthelp\.com\//i, | ||
/metrics\.itunes\.apple\.com\.edgesuite\.net\//i, | ||
], | ||
}) |