Skip to content

Commit

Permalink
chore: add sentry plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
ruofee committed Mar 19, 2024
1 parent 85ad48a commit 01ce436
Show file tree
Hide file tree
Showing 3 changed files with 101 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/.vuepress/enhanceApp.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,26 @@
import * as Sentry from "@sentry/vue";
import VueEllipsis from '../../lib/vue-ellipsis-component';

export default ({
Vue
}) => {
Vue.use(VueEllipsis);
Sentry.init({
Vue,
dsn: "https://278a1d4007dfc1d0ba943a81582d42af@o196334.ingest.us.sentry.io/4506935647666176",
integrations: [
Sentry.browserTracingIntegration(),
Sentry.replayIntegration({
maskAllText: false,
blockAllMedia: false,
}),
],
// Performance Monitoring
tracesSampleRate: 1.0, // Capture 100% of the transactions
// Set 'tracePropagationTargets' to control for which URLs distributed tracing should be enabled
tracePropagationTargets: ["localhost", /^https:\/\/vue-ellipsis\.ruofee\.cn/],
// Session Replay
replaysSessionSampleRate: 0.1, // This sets the sample rate at 10%. You may want to change it to 100% while in development and then sample at a lower rate in production.
replaysOnErrorSampleRate: 1.0, // If you're not already sampling the entire session, change the sample rate to 100% when sampling sessions where errors occur.
});
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"docs:build": "yarn build && vuepress build docs"
},
"devDependencies": {
"@sentry/vue": "^7.107.0",
"@types/jest": "^24.0.19",
"@types/resize-observer-browser": "^0.1.6",
"@vue/eslint-config-typescript": "^10.0.0",
Expand Down
81 changes: 81 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1236,6 +1236,87 @@
estree-walker "^2.0.1"
picomatch "^2.2.2"

"@sentry-internal/feedback@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry-internal/feedback/-/feedback-7.107.0.tgz#144cf01b1c1739d61db3990519f59b49a356fef1"
integrity sha512-okF0B9AJHrpkwNMxNs/Lffw3N5ZNbGwz4uvCfyOfnMxc7E2VfDM18QzUvTBRvNr3bA9wl+InJ+EMG3aZhyPunA==
dependencies:
"@sentry/core" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry-internal/replay-canvas@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry-internal/replay-canvas/-/replay-canvas-7.107.0.tgz#ce2a8f6bf63ab962e696f26b509cfb87aa931302"
integrity sha512-dmDL9g3QDfo7axBOsVnpiKdJ/DXrdeuRv1AqsLgwzJKvItsv0ZizX0u+rj5b1UoxcwbXRMxJ0hit5a1yt3t/ow==
dependencies:
"@sentry/core" "7.107.0"
"@sentry/replay" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry-internal/tracing@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry-internal/tracing/-/tracing-7.107.0.tgz#a10b4abcbc9e0d8da948e3a95029574387ca7b16"
integrity sha512-le9wM8+OHBbq7m/8P7JUJ1UhSPIty+Z/HmRXc5Z64ODZcOwFV6TmDpYx729IXDdz36XUKmeI+BeM7yQdTTZPfQ==
dependencies:
"@sentry/core" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry/browser@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-7.107.0.tgz#a1caf4a3c39857862ba3314b9d4ed03f9259f338"
integrity sha512-KnqaQDhxv6w9dJ+mYLsNwPeGZfgbpM3vaismBNyJCKLgWn2V75kxkSq+bDX8LQT/13AyK7iFp317L6P8EuNa3g==
dependencies:
"@sentry-internal/feedback" "7.107.0"
"@sentry-internal/replay-canvas" "7.107.0"
"@sentry-internal/tracing" "7.107.0"
"@sentry/core" "7.107.0"
"@sentry/replay" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry/core@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-7.107.0.tgz#926838ba2c2861d6bd2bced0232e1f9d1ead6c75"
integrity sha512-C7ogye6+KPyBi8NVL0P8Rxx3Ur7Td8ufnjxosVy678lqY+dcYPk/HONROrzUFYW5fMKWL4/KYnwP+x9uHnkDmw==
dependencies:
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry/replay@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/replay/-/replay-7.107.0.tgz#d714f864ef8602e6d009b2fa8ff8e4ef63c3e9e4"
integrity sha512-BNJDEVaEwr/YnV22qnyVA1almx/3p615m3+KaF8lPo7YleYgJGSJv1auH64j1G8INkrJ0J0wFBujb1EFjMYkxA==
dependencies:
"@sentry-internal/tracing" "7.107.0"
"@sentry/core" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sentry/types@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-7.107.0.tgz#5ba4b472be6ccad9aecd58dbc0141a09dafb68c1"
integrity sha512-H7qcPjPSUWHE/Zf5bR1EE24G0pGVuJgrSx8Tvvl5nKEepswMYlbXHRVSDN0gTk/E5Z7cqf+hUBOpkQgZyps77w==

"@sentry/utils@7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.107.0.tgz#b8524539d052a40f9c5f34a8347501f0f81a0751"
integrity sha512-C6PbN5gHh73MRHohnReeQ60N8rrLYa9LciHue3Ru2290eSThg4CzsPnx4SzkGpkSeVlhhptKtKZ+hp/ha3iVuw==
dependencies:
"@sentry/types" "7.107.0"

"@sentry/vue@^7.107.0":
version "7.107.0"
resolved "https://registry.yarnpkg.com/@sentry/vue/-/vue-7.107.0.tgz#40cb1589f18338ce1effda89794d567d1f40ee48"
integrity sha512-nUUaa5s2W7UmgjavoksoBlduc6mePZmo4k3y5lXPhSvZ92FcidLZItRUkwubaUBHgu8zvRxkTeXGhbqfWN4Ukg==
dependencies:
"@sentry/browser" "7.107.0"
"@sentry/core" "7.107.0"
"@sentry/types" "7.107.0"
"@sentry/utils" "7.107.0"

"@sindresorhus/is@^0.14.0":
version "0.14.0"
resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.14.0.tgz#9fb3a3cf3132328151f353de4632e01e52102bea"
Expand Down

0 comments on commit 01ce436

Please sign in to comment.