MCPcopy Index your code
hub / github.com/getsentry/sentry-javascript / checkAndSetAngularVersion

Function checkAndSetAngularVersion

packages/angular/src/sdk.ts:67–84  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

65}
66
67function checkAndSetAngularVersion(): void {
68 const ANGULAR_MINIMUM_VERSION = 14;
69
70 const angularVersion = VERSION?.major && parseInt(VERSION.major, 10);
71
72 if (angularVersion) {
73 if (angularVersion < ANGULAR_MINIMUM_VERSION) {
74 IS_DEBUG_BUILD &&
75 debug.warn(
76 `This Sentry SDK does not officially support Angular ${angularVersion}.`,
77 `This SDK only supports Angular ${ANGULAR_MINIMUM_VERSION} and above.`,
78 "If you're using lower Angular versions, check the Angular Version Compatibility table in our docs: https://docs.sentry.io/platforms/javascript/guides/angular/#angular-version-compatibility.",
79 'Otherwise, please consider upgrading your Angular version.',
80 );
81 }
82 setContext('angular', { version: angularVersion });
83 }
84}

Callers 1

initFunction · 0.85

Calls 2

warnMethod · 0.65
setContextFunction · 0.50

Tested by

no test coverage detected