@sentry/gatsby 7.15.0 → 7.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +11 -26
- package/cjs/index.js +4 -4
- package/cjs/sdk.js +3 -3
- package/cjs/sdk.js.map +1 -1
- package/cjs/utils/integrations.js +3 -3
- package/cjs/utils/integrations.js.map +1 -1
- package/esm/sdk.js +1 -1
- package/esm/sdk.js.map +1 -1
- package/esm/utils/integrations.js +2 -2
- package/esm/utils/integrations.js.map +1 -1
- package/package.json +6 -6
package/LICENSE
CHANGED
|
@@ -1,29 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
Copyright (c) 2020 Sentry (https://sentry.io) and individual contributors. All rights reserved.
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
|
|
4
|
+
documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
|
|
5
|
+
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit
|
|
6
|
+
persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
5
7
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
|
|
9
|
+
Software.
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
this list of conditions and the following disclaimer in the documentation
|
|
14
|
-
and/or other materials provided with the distribution.
|
|
15
|
-
|
|
16
|
-
* Neither the name of the copyright holder nor the names of its
|
|
17
|
-
contributors may be used to endorse or promote products derived from
|
|
18
|
-
this software without specific prior written permission.
|
|
19
|
-
|
|
20
|
-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
21
|
-
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
22
|
-
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
23
|
-
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
24
|
-
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
25
|
-
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
26
|
-
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
27
|
-
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
28
|
-
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
29
|
-
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
11
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
|
|
12
|
+
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
13
|
+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
|
14
|
+
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/cjs/index.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
const react = require('@sentry/react');
|
|
4
|
+
const Tracing = require('@sentry/tracing');
|
|
5
|
+
const sdk = require('./sdk.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
exports.Integrations = Tracing.Integrations;
|
|
10
10
|
exports.init = sdk.init;
|
|
11
|
-
for (
|
|
11
|
+
for (const k in react) {
|
|
12
12
|
if (k !== 'default' && !exports.hasOwnProperty(k)) exports[k] = react[k];
|
|
13
13
|
}
|
|
14
14
|
//# sourceMappingURL=index.js.map
|
package/cjs/sdk.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
const react = require('@sentry/react');
|
|
4
|
+
const integrations = require('./utils/integrations.js');
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Inits the Sentry Gatsby SDK.
|
|
@@ -19,7 +19,7 @@ function init(options) {
|
|
|
19
19
|
version: react.SDK_VERSION,
|
|
20
20
|
};
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
const integrations$1 = integrations.getIntegrationsFromOptions(options);
|
|
23
23
|
react.init({
|
|
24
24
|
...options,
|
|
25
25
|
integrations: integrations$1,
|
package/cjs/sdk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.js","sources":["../../src/sdk.ts"],"sourcesContent":["import { init as reactInit, SDK_VERSION } from '@sentry/react';\n\nimport { getIntegrationsFromOptions } from './utils/integrations';\nimport { GatsbyOptions } from './utils/types';\n\n/**\n * Inits the Sentry Gatsby SDK.\n */\nexport function init(options: GatsbyOptions): void {\n options._metadata = options._metadata || {};\n options._metadata.sdk = options._metadata.sdk || {\n name: 'sentry.javascript.gatsby',\n packages: [\n {\n name: 'npm:@sentry/gatsby',\n version: SDK_VERSION,\n },\n ],\n version: SDK_VERSION,\n };\n\n const integrations = getIntegrationsFromOptions(options);\n reactInit({\n ...options,\n integrations,\n });\n}\n"],"names":[],"mappings":";;;;;AAKA;AACA;AACA
|
|
1
|
+
{"version":3,"file":"sdk.js","sources":["../../src/sdk.ts"],"sourcesContent":["import { init as reactInit, SDK_VERSION } from '@sentry/react';\n\nimport { getIntegrationsFromOptions } from './utils/integrations';\nimport { GatsbyOptions } from './utils/types';\n\n/**\n * Inits the Sentry Gatsby SDK.\n */\nexport function init(options: GatsbyOptions): void {\n options._metadata = options._metadata || {};\n options._metadata.sdk = options._metadata.sdk || {\n name: 'sentry.javascript.gatsby',\n packages: [\n {\n name: 'npm:@sentry/gatsby',\n version: SDK_VERSION,\n },\n ],\n version: SDK_VERSION,\n };\n\n const integrations = getIntegrationsFromOptions(options);\n reactInit({\n ...options,\n integrations,\n });\n}\n"],"names":["SDK_VERSION","integrations","getIntegrationsFromOptions","reactInit"],"mappings":";;;;;AAKA;AACA;AACA;AACA,SAAA,IAAA,CAAA,OAAA,EAAA;AACA,EAAA,OAAA,CAAA,SAAA,GAAA,OAAA,CAAA,SAAA,IAAA,EAAA,CAAA;AACA,EAAA,OAAA,CAAA,SAAA,CAAA,GAAA,GAAA,OAAA,CAAA,SAAA,CAAA,GAAA,IAAA;AACA,IAAA,IAAA,EAAA,0BAAA;AACA,IAAA,QAAA,EAAA;AACA,MAAA;AACA,QAAA,IAAA,EAAA,oBAAA;AACA,QAAA,OAAA,EAAAA,iBAAA;AACA,OAAA;AACA,KAAA;AACA,IAAA,OAAA,EAAAA,iBAAA;AACA,GAAA,CAAA;AACA;AACA,EAAA,MAAAC,cAAA,GAAAC,uCAAA,CAAA,OAAA,CAAA,CAAA;AACA,EAAAC,UAAA,CAAA;AACA,IAAA,GAAA,OAAA;AACA,kBAAAF,cAAA;AACA,GAAA,CAAA,CAAA;AACA;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
const Tracing = require('@sentry/tracing');
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Returns the integrations to add to the SDK.
|
|
@@ -9,7 +9,7 @@ var Tracing = require('@sentry/tracing');
|
|
|
9
9
|
* @param options The options users have defined.
|
|
10
10
|
*/
|
|
11
11
|
function getIntegrationsFromOptions(options) {
|
|
12
|
-
|
|
12
|
+
const isTracingEnabled = Tracing.hasTracingEnabled(options);
|
|
13
13
|
if (options.integrations === undefined) {
|
|
14
14
|
return getIntegrationsFromArray([], isTracingEnabled);
|
|
15
15
|
} else if (Array.isArray(options.integrations)) {
|
|
@@ -45,7 +45,7 @@ function getIntegrationsFromFunction(
|
|
|
45
45
|
userIntegrations,
|
|
46
46
|
isTracingEnabled,
|
|
47
47
|
) {
|
|
48
|
-
|
|
48
|
+
const wrapper = (defaultIntegrations) => {
|
|
49
49
|
return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);
|
|
50
50
|
};
|
|
51
51
|
return wrapper;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"integrations.js","sources":["../../../src/utils/integrations.ts"],"sourcesContent":["import * as Tracing from '@sentry/tracing';\nimport { Integration } from '@sentry/types';\n\nimport { GatsbyOptions } from './types';\n\ntype UserFnIntegrations = (integrations: Integration[]) => Integration[];\nexport type UserIntegrations = Integration[] | UserFnIntegrations;\n\n/**\n * Returns the integrations to add to the SDK.\n * If tracing is enabled, `BrowserTracing` is always present.\n *\n * @param options The options users have defined.\n */\nexport function getIntegrationsFromOptions(options: GatsbyOptions): UserIntegrations {\n const isTracingEnabled = Tracing.hasTracingEnabled(options);\n if (options.integrations === undefined) {\n return getIntegrationsFromArray([], isTracingEnabled);\n } else if (Array.isArray(options.integrations)) {\n return getIntegrationsFromArray(options.integrations, isTracingEnabled);\n } else {\n return getIntegrationsFromFunction(options.integrations, isTracingEnabled);\n }\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given integrations array.\n *\n * @param userIntegrations Array of user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromArray(userIntegrations: Integration[], isTracingEnabled: boolean): Integration[] {\n if (\n isTracingEnabled &&\n !userIntegrations.some(integration => integration.name === Tracing.Integrations.BrowserTracing.name)\n ) {\n userIntegrations.push(new Tracing.Integrations.BrowserTracing());\n }\n return userIntegrations;\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given function.\n *\n * @param userIntegrations Function returning the user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromFunction(\n userIntegrations: UserFnIntegrations,\n isTracingEnabled: boolean,\n): UserFnIntegrations {\n const wrapper: UserFnIntegrations = (defaultIntegrations: Integration[]) => {\n return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);\n };\n return wrapper;\n}\n"],"names":[],"mappings":";;;;AAQA;AACA;AACA;AACA;AACA;AACA
|
|
1
|
+
{"version":3,"file":"integrations.js","sources":["../../../src/utils/integrations.ts"],"sourcesContent":["import * as Tracing from '@sentry/tracing';\nimport { Integration } from '@sentry/types';\n\nimport { GatsbyOptions } from './types';\n\ntype UserFnIntegrations = (integrations: Integration[]) => Integration[];\nexport type UserIntegrations = Integration[] | UserFnIntegrations;\n\n/**\n * Returns the integrations to add to the SDK.\n * If tracing is enabled, `BrowserTracing` is always present.\n *\n * @param options The options users have defined.\n */\nexport function getIntegrationsFromOptions(options: GatsbyOptions): UserIntegrations {\n const isTracingEnabled = Tracing.hasTracingEnabled(options);\n if (options.integrations === undefined) {\n return getIntegrationsFromArray([], isTracingEnabled);\n } else if (Array.isArray(options.integrations)) {\n return getIntegrationsFromArray(options.integrations, isTracingEnabled);\n } else {\n return getIntegrationsFromFunction(options.integrations, isTracingEnabled);\n }\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given integrations array.\n *\n * @param userIntegrations Array of user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromArray(userIntegrations: Integration[], isTracingEnabled: boolean): Integration[] {\n if (\n isTracingEnabled &&\n !userIntegrations.some(integration => integration.name === Tracing.Integrations.BrowserTracing.name)\n ) {\n userIntegrations.push(new Tracing.Integrations.BrowserTracing());\n }\n return userIntegrations;\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given function.\n *\n * @param userIntegrations Function returning the user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromFunction(\n userIntegrations: UserFnIntegrations,\n isTracingEnabled: boolean,\n): UserFnIntegrations {\n const wrapper: UserFnIntegrations = (defaultIntegrations: Integration[]) => {\n return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);\n };\n return wrapper;\n}\n"],"names":[],"mappings":";;;;AAQA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,0BAAA,CAAA,OAAA,EAAA;AACA,EAAA,MAAA,gBAAA,GAAA,OAAA,CAAA,iBAAA,CAAA,OAAA,CAAA,CAAA;AACA,EAAA,IAAA,OAAA,CAAA,YAAA,KAAA,SAAA,EAAA;AACA,IAAA,OAAA,wBAAA,CAAA,EAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,MAAA,IAAA,KAAA,CAAA,OAAA,CAAA,OAAA,CAAA,YAAA,CAAA,EAAA;AACA,IAAA,OAAA,wBAAA,CAAA,OAAA,CAAA,YAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,MAAA;AACA,IAAA,OAAA,2BAAA,CAAA,OAAA,CAAA,YAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA;AACA,CAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,wBAAA,CAAA,gBAAA,EAAA,gBAAA,EAAA;AACA,EAAA;AACA,IAAA,gBAAA;AACA,IAAA,CAAA,gBAAA,CAAA,IAAA,CAAA,WAAA,IAAA,WAAA,CAAA,IAAA,KAAA,OAAA,CAAA,YAAA,CAAA,cAAA,CAAA,IAAA,CAAA;AACA,IAAA;AACA,IAAA,gBAAA,CAAA,IAAA,CAAA,IAAA,OAAA,CAAA,YAAA,CAAA,cAAA,EAAA,CAAA,CAAA;AACA,GAAA;AACA,EAAA,OAAA,gBAAA,CAAA;AACA,CAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,2BAAA;AACA,EAAA,gBAAA;AACA,EAAA,gBAAA;AACA,EAAA;AACA,EAAA,MAAA,OAAA,GAAA,CAAA,mBAAA,KAAA;AACA,IAAA,OAAA,wBAAA,CAAA,gBAAA,CAAA,mBAAA,CAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,CAAA;AACA,EAAA,OAAA,OAAA,CAAA;AACA;;;;"}
|
package/esm/sdk.js
CHANGED
package/esm/sdk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.js","sources":["../../src/sdk.ts"],"sourcesContent":["import { init as reactInit, SDK_VERSION } from '@sentry/react';\n\nimport { getIntegrationsFromOptions } from './utils/integrations';\nimport { GatsbyOptions } from './utils/types';\n\n/**\n * Inits the Sentry Gatsby SDK.\n */\nexport function init(options: GatsbyOptions): void {\n options._metadata = options._metadata || {};\n options._metadata.sdk = options._metadata.sdk || {\n name: 'sentry.javascript.gatsby',\n packages: [\n {\n name: 'npm:@sentry/gatsby',\n version: SDK_VERSION,\n },\n ],\n version: SDK_VERSION,\n };\n\n const integrations = getIntegrationsFromOptions(options);\n reactInit({\n ...options,\n integrations,\n });\n}\n"],"names":[],"mappings":";;;AAKA;AACA;AACA
|
|
1
|
+
{"version":3,"file":"sdk.js","sources":["../../src/sdk.ts"],"sourcesContent":["import { init as reactInit, SDK_VERSION } from '@sentry/react';\n\nimport { getIntegrationsFromOptions } from './utils/integrations';\nimport { GatsbyOptions } from './utils/types';\n\n/**\n * Inits the Sentry Gatsby SDK.\n */\nexport function init(options: GatsbyOptions): void {\n options._metadata = options._metadata || {};\n options._metadata.sdk = options._metadata.sdk || {\n name: 'sentry.javascript.gatsby',\n packages: [\n {\n name: 'npm:@sentry/gatsby',\n version: SDK_VERSION,\n },\n ],\n version: SDK_VERSION,\n };\n\n const integrations = getIntegrationsFromOptions(options);\n reactInit({\n ...options,\n integrations,\n });\n}\n"],"names":["reactInit"],"mappings":";;;AAKA;AACA;AACA;AACA,SAAA,IAAA,CAAA,OAAA,EAAA;AACA,EAAA,OAAA,CAAA,SAAA,GAAA,OAAA,CAAA,SAAA,IAAA,EAAA,CAAA;AACA,EAAA,OAAA,CAAA,SAAA,CAAA,GAAA,GAAA,OAAA,CAAA,SAAA,CAAA,GAAA,IAAA;AACA,IAAA,IAAA,EAAA,0BAAA;AACA,IAAA,QAAA,EAAA;AACA,MAAA;AACA,QAAA,IAAA,EAAA,oBAAA;AACA,QAAA,OAAA,EAAA,WAAA;AACA,OAAA;AACA,KAAA;AACA,IAAA,OAAA,EAAA,WAAA;AACA,GAAA,CAAA;AACA;AACA,EAAA,MAAA,YAAA,GAAA,0BAAA,CAAA,OAAA,CAAA,CAAA;AACA,EAAAA,MAAA,CAAA;AACA,IAAA,GAAA,OAAA;AACA,IAAA,YAAA;AACA,GAAA,CAAA,CAAA;AACA;;;;"}
|
|
@@ -7,7 +7,7 @@ import * as Tracing from '@sentry/tracing';
|
|
|
7
7
|
* @param options The options users have defined.
|
|
8
8
|
*/
|
|
9
9
|
function getIntegrationsFromOptions(options) {
|
|
10
|
-
|
|
10
|
+
const isTracingEnabled = Tracing.hasTracingEnabled(options);
|
|
11
11
|
if (options.integrations === undefined) {
|
|
12
12
|
return getIntegrationsFromArray([], isTracingEnabled);
|
|
13
13
|
} else if (Array.isArray(options.integrations)) {
|
|
@@ -43,7 +43,7 @@ function getIntegrationsFromFunction(
|
|
|
43
43
|
userIntegrations,
|
|
44
44
|
isTracingEnabled,
|
|
45
45
|
) {
|
|
46
|
-
|
|
46
|
+
const wrapper = (defaultIntegrations) => {
|
|
47
47
|
return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);
|
|
48
48
|
};
|
|
49
49
|
return wrapper;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"integrations.js","sources":["../../../src/utils/integrations.ts"],"sourcesContent":["import * as Tracing from '@sentry/tracing';\nimport { Integration } from '@sentry/types';\n\nimport { GatsbyOptions } from './types';\n\ntype UserFnIntegrations = (integrations: Integration[]) => Integration[];\nexport type UserIntegrations = Integration[] | UserFnIntegrations;\n\n/**\n * Returns the integrations to add to the SDK.\n * If tracing is enabled, `BrowserTracing` is always present.\n *\n * @param options The options users have defined.\n */\nexport function getIntegrationsFromOptions(options: GatsbyOptions): UserIntegrations {\n const isTracingEnabled = Tracing.hasTracingEnabled(options);\n if (options.integrations === undefined) {\n return getIntegrationsFromArray([], isTracingEnabled);\n } else if (Array.isArray(options.integrations)) {\n return getIntegrationsFromArray(options.integrations, isTracingEnabled);\n } else {\n return getIntegrationsFromFunction(options.integrations, isTracingEnabled);\n }\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given integrations array.\n *\n * @param userIntegrations Array of user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromArray(userIntegrations: Integration[], isTracingEnabled: boolean): Integration[] {\n if (\n isTracingEnabled &&\n !userIntegrations.some(integration => integration.name === Tracing.Integrations.BrowserTracing.name)\n ) {\n userIntegrations.push(new Tracing.Integrations.BrowserTracing());\n }\n return userIntegrations;\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given function.\n *\n * @param userIntegrations Function returning the user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromFunction(\n userIntegrations: UserFnIntegrations,\n isTracingEnabled: boolean,\n): UserFnIntegrations {\n const wrapper: UserFnIntegrations = (defaultIntegrations: Integration[]) => {\n return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);\n };\n return wrapper;\n}\n"],"names":[],"mappings":";;AAQA;AACA;AACA;AACA;AACA;AACA
|
|
1
|
+
{"version":3,"file":"integrations.js","sources":["../../../src/utils/integrations.ts"],"sourcesContent":["import * as Tracing from '@sentry/tracing';\nimport { Integration } from '@sentry/types';\n\nimport { GatsbyOptions } from './types';\n\ntype UserFnIntegrations = (integrations: Integration[]) => Integration[];\nexport type UserIntegrations = Integration[] | UserFnIntegrations;\n\n/**\n * Returns the integrations to add to the SDK.\n * If tracing is enabled, `BrowserTracing` is always present.\n *\n * @param options The options users have defined.\n */\nexport function getIntegrationsFromOptions(options: GatsbyOptions): UserIntegrations {\n const isTracingEnabled = Tracing.hasTracingEnabled(options);\n if (options.integrations === undefined) {\n return getIntegrationsFromArray([], isTracingEnabled);\n } else if (Array.isArray(options.integrations)) {\n return getIntegrationsFromArray(options.integrations, isTracingEnabled);\n } else {\n return getIntegrationsFromFunction(options.integrations, isTracingEnabled);\n }\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given integrations array.\n *\n * @param userIntegrations Array of user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromArray(userIntegrations: Integration[], isTracingEnabled: boolean): Integration[] {\n if (\n isTracingEnabled &&\n !userIntegrations.some(integration => integration.name === Tracing.Integrations.BrowserTracing.name)\n ) {\n userIntegrations.push(new Tracing.Integrations.BrowserTracing());\n }\n return userIntegrations;\n}\n\n/**\n * Returns the integrations to add to the SDK, from the given function.\n *\n * @param userIntegrations Function returning the user's integrations.\n * @param isTracingEnabled Whether the user has enabled tracing.\n */\nfunction getIntegrationsFromFunction(\n userIntegrations: UserFnIntegrations,\n isTracingEnabled: boolean,\n): UserFnIntegrations {\n const wrapper: UserFnIntegrations = (defaultIntegrations: Integration[]) => {\n return getIntegrationsFromArray(userIntegrations(defaultIntegrations), isTracingEnabled);\n };\n return wrapper;\n}\n"],"names":[],"mappings":";;AAQA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,0BAAA,CAAA,OAAA,EAAA;AACA,EAAA,MAAA,gBAAA,GAAA,OAAA,CAAA,iBAAA,CAAA,OAAA,CAAA,CAAA;AACA,EAAA,IAAA,OAAA,CAAA,YAAA,KAAA,SAAA,EAAA;AACA,IAAA,OAAA,wBAAA,CAAA,EAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,MAAA,IAAA,KAAA,CAAA,OAAA,CAAA,OAAA,CAAA,YAAA,CAAA,EAAA;AACA,IAAA,OAAA,wBAAA,CAAA,OAAA,CAAA,YAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,MAAA;AACA,IAAA,OAAA,2BAAA,CAAA,OAAA,CAAA,YAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA;AACA,CAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,wBAAA,CAAA,gBAAA,EAAA,gBAAA,EAAA;AACA,EAAA;AACA,IAAA,gBAAA;AACA,IAAA,CAAA,gBAAA,CAAA,IAAA,CAAA,WAAA,IAAA,WAAA,CAAA,IAAA,KAAA,OAAA,CAAA,YAAA,CAAA,cAAA,CAAA,IAAA,CAAA;AACA,IAAA;AACA,IAAA,gBAAA,CAAA,IAAA,CAAA,IAAA,OAAA,CAAA,YAAA,CAAA,cAAA,EAAA,CAAA,CAAA;AACA,GAAA;AACA,EAAA,OAAA,gBAAA,CAAA;AACA,CAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAA,2BAAA;AACA,EAAA,gBAAA;AACA,EAAA,gBAAA;AACA,EAAA;AACA,EAAA,MAAA,OAAA,GAAA,CAAA,mBAAA,KAAA;AACA,IAAA,OAAA,wBAAA,CAAA,gBAAA,CAAA,mBAAA,CAAA,EAAA,gBAAA,CAAA,CAAA;AACA,GAAA,CAAA;AACA,EAAA,OAAA,OAAA,CAAA;AACA;;;;"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/gatsby",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.17.0",
|
|
4
4
|
"description": "Official Sentry SDK for Gatsby.js",
|
|
5
5
|
"repository": "git://github.com/getsentry/sentry-javascript.git",
|
|
6
6
|
"homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/gatsby",
|
|
7
7
|
"author": "Sentry",
|
|
8
|
-
"license": "
|
|
8
|
+
"license": "MIT",
|
|
9
9
|
"keywords": [
|
|
10
10
|
"gatsby",
|
|
11
11
|
"gatsby-plugin"
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
"access": "public"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@sentry/react": "7.
|
|
24
|
-
"@sentry/tracing": "7.
|
|
25
|
-
"@sentry/types": "7.
|
|
26
|
-
"@sentry/utils": "7.
|
|
23
|
+
"@sentry/react": "7.17.0",
|
|
24
|
+
"@sentry/tracing": "7.17.0",
|
|
25
|
+
"@sentry/types": "7.17.0",
|
|
26
|
+
"@sentry/utils": "7.17.0",
|
|
27
27
|
"@sentry/webpack-plugin": "1.19.0"
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|