@sentry/solidstart 10.70.0 → 11.0.0-alpha.1
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/README.md +65 -0
- package/build/cjs/config/addInstrumentation.js +0 -1
- package/build/cjs/config/addInstrumentation.js.map +1 -1
- package/build/cjs/config/withSentry.js +20 -1
- package/build/cjs/config/withSentry.js.map +1 -1
- package/build/cjs/config/wrapServerEntryWithDynamicImport.js +1 -6
- package/build/cjs/config/wrapServerEntryWithDynamicImport.js.map +1 -1
- package/build/cjs/index.server.js +2 -4
- package/build/cjs/index.server.js.map +1 -1
- package/build/cjs/server/index.js +2 -4
- package/build/cjs/server/index.js.map +1 -1
- package/build/cjs/server/withServerActionInstrumentation.js +8 -5
- package/build/cjs/server/withServerActionInstrumentation.js.map +1 -1
- package/build/cjs/vite/index.js +8 -0
- package/build/cjs/vite/index.js.map +1 -0
- package/build/cjs/vite/sentrySolidStart.js +36 -0
- package/build/cjs/vite/sentrySolidStart.js.map +1 -0
- package/build/cjs/vite/sourceMaps.js +64 -5
- package/build/cjs/vite/sourceMaps.js.map +1 -1
- package/build/esm/config/addInstrumentation.js +0 -1
- package/build/esm/config/addInstrumentation.js.map +1 -1
- package/build/esm/config/withSentry.js +20 -1
- package/build/esm/config/withSentry.js.map +1 -1
- package/build/esm/config/wrapServerEntryWithDynamicImport.js +1 -6
- package/build/esm/config/wrapServerEntryWithDynamicImport.js.map +1 -1
- package/build/esm/index.server.js +1 -1
- package/build/esm/package.json +1 -1
- package/build/esm/server/index.js +1 -1
- package/build/esm/server/withServerActionInstrumentation.js +9 -6
- package/build/esm/server/withServerActionInstrumentation.js.map +1 -1
- package/build/esm/vite/index.js +2 -0
- package/build/esm/vite/index.js.map +1 -0
- package/build/esm/vite/sentrySolidStart.js +34 -0
- package/build/esm/vite/sentrySolidStart.js.map +1 -0
- package/build/esm/vite/sourceMaps.js +63 -5
- package/build/esm/vite/sourceMaps.js.map +1 -1
- package/build/types/config/addInstrumentation.d.ts +1 -1
- package/build/types/config/addInstrumentation.d.ts.map +1 -1
- package/build/types/config/withSentry.d.ts.map +1 -1
- package/build/types/config/wrapServerEntryWithDynamicImport.d.ts +0 -2
- package/build/types/config/wrapServerEntryWithDynamicImport.d.ts.map +1 -1
- package/build/types/index.types.d.ts +1 -0
- package/build/types/index.types.d.ts.map +1 -1
- package/build/types/server/index.d.ts +1 -1
- package/build/types/server/index.d.ts.map +1 -1
- package/build/types/server/middleware.d.ts.map +1 -1
- package/build/types/server/withServerActionInstrumentation.d.ts.map +1 -1
- package/build/types/vite/index.d.ts +3 -0
- package/build/types/vite/index.d.ts.map +1 -0
- package/build/types/vite/sentrySolidStart.d.ts +37 -0
- package/build/types/vite/sentrySolidStart.d.ts.map +1 -0
- package/build/types/vite/sentrySolidStartVite.d.ts.map +1 -1
- package/build/types/vite/sourceMaps.d.ts +18 -4
- package/build/types/vite/sourceMaps.d.ts.map +1 -1
- package/build/types/vite/types.d.ts +10 -2
- package/build/types/vite/types.d.ts.map +1 -1
- package/package.json +26 -9
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { sentryVitePlugin } from '@sentry/vite
|
|
1
|
+
import { sentryVitePlugin } from '@sentry/bundler-plugins/vite';
|
|
2
2
|
|
|
3
3
|
function makeAddSentryVitePlugin(options, viteConfig) {
|
|
4
4
|
const { authToken, debug, org, project, sourceMapsUploadOptions } = options;
|
|
@@ -34,6 +34,67 @@ function makeAddSentryVitePlugin(options, viteConfig) {
|
|
|
34
34
|
})
|
|
35
35
|
];
|
|
36
36
|
}
|
|
37
|
+
function makeAddSentryVitePluginSolidStart2(options) {
|
|
38
|
+
const {
|
|
39
|
+
authToken,
|
|
40
|
+
buildTimeInstrumentation: _buildTimeInstrumentation,
|
|
41
|
+
debug,
|
|
42
|
+
org,
|
|
43
|
+
project,
|
|
44
|
+
sentryUrl,
|
|
45
|
+
sourcemaps,
|
|
46
|
+
telemetry,
|
|
47
|
+
unstable_sentryVitePluginOptions,
|
|
48
|
+
...passthroughOptions
|
|
49
|
+
} = options;
|
|
50
|
+
let resolveFilesToDeleteAfterUpload;
|
|
51
|
+
const filesToDeleteAfterUploadPromise = new Promise((resolve) => {
|
|
52
|
+
resolveFilesToDeleteAfterUpload = resolve;
|
|
53
|
+
});
|
|
54
|
+
const configPlugin = {
|
|
55
|
+
name: "sentry-solidstart-files-to-delete-after-upload",
|
|
56
|
+
apply: "build",
|
|
57
|
+
enforce: "post",
|
|
58
|
+
config(config) {
|
|
59
|
+
const userFilesToDelete = sourcemaps?.filesToDeleteAfterUpload ?? unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload;
|
|
60
|
+
if (typeof userFilesToDelete === "undefined" && typeof config.build?.sourcemap === "undefined") {
|
|
61
|
+
if (debug) {
|
|
62
|
+
console.log(
|
|
63
|
+
'[Sentry] Automatically setting `sourcemaps.filesToDeleteAfterUpload: ["./**/*.map"]` to delete generated source maps after they were uploaded to Sentry.'
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
resolveFilesToDeleteAfterUpload?.(["./**/*.map"]);
|
|
67
|
+
} else {
|
|
68
|
+
resolveFilesToDeleteAfterUpload?.(userFilesToDelete);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
const sentryPlugins = sentryVitePlugin({
|
|
73
|
+
...passthroughOptions,
|
|
74
|
+
authToken: authToken ?? process.env.SENTRY_AUTH_TOKEN,
|
|
75
|
+
debug: debug ?? false,
|
|
76
|
+
org: org ?? process.env.SENTRY_ORG,
|
|
77
|
+
project: project ?? process.env.SENTRY_PROJECT,
|
|
78
|
+
telemetry: telemetry ?? true,
|
|
79
|
+
url: sentryUrl,
|
|
80
|
+
// Spread here so it overrides the plain options above, but not the objects merged below —
|
|
81
|
+
// spreading replaces whole keys rather than deep-merging.
|
|
82
|
+
...unstable_sentryVitePluginOptions,
|
|
83
|
+
sourcemaps: {
|
|
84
|
+
...sourcemaps,
|
|
85
|
+
...unstable_sentryVitePluginOptions?.sourcemaps,
|
|
86
|
+
filesToDeleteAfterUpload: filesToDeleteAfterUploadPromise
|
|
87
|
+
},
|
|
88
|
+
_metaOptions: {
|
|
89
|
+
...unstable_sentryVitePluginOptions?._metaOptions,
|
|
90
|
+
telemetry: {
|
|
91
|
+
...unstable_sentryVitePluginOptions?._metaOptions?.telemetry,
|
|
92
|
+
metaFramework: "solidstart"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
return [configPlugin, ...sentryPlugins];
|
|
97
|
+
}
|
|
37
98
|
function makeEnableSourceMapsVitePlugin(options) {
|
|
38
99
|
return [
|
|
39
100
|
{
|
|
@@ -42,9 +103,7 @@ function makeEnableSourceMapsVitePlugin(options) {
|
|
|
42
103
|
enforce: "post",
|
|
43
104
|
config(viteConfig) {
|
|
44
105
|
return {
|
|
45
|
-
...viteConfig,
|
|
46
106
|
build: {
|
|
47
|
-
...viteConfig.build,
|
|
48
107
|
sourcemap: getUpdatedSourceMapSettings(viteConfig, options)
|
|
49
108
|
}
|
|
50
109
|
};
|
|
@@ -53,7 +112,6 @@ function makeEnableSourceMapsVitePlugin(options) {
|
|
|
53
112
|
];
|
|
54
113
|
}
|
|
55
114
|
function getUpdatedSourceMapSettings(viteConfig, sentryPluginOptions) {
|
|
56
|
-
viteConfig.build = viteConfig.build || {};
|
|
57
115
|
const viteSourceMap = viteConfig?.build?.sourcemap;
|
|
58
116
|
let updatedSourceMapSetting = viteSourceMap;
|
|
59
117
|
const settingKey = "vite.build.sourcemap";
|
|
@@ -83,5 +141,5 @@ function getUpdatedSourceMapSettings(viteConfig, sentryPluginOptions) {
|
|
|
83
141
|
return updatedSourceMapSetting;
|
|
84
142
|
}
|
|
85
143
|
|
|
86
|
-
export { getUpdatedSourceMapSettings, makeAddSentryVitePlugin, makeEnableSourceMapsVitePlugin };
|
|
144
|
+
export { getUpdatedSourceMapSettings, makeAddSentryVitePlugin, makeAddSentryVitePluginSolidStart2, makeEnableSourceMapsVitePlugin };
|
|
87
145
|
//# sourceMappingURL=sourceMaps.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sourceMaps.js","sources":["../../../src/vite/sourceMaps.ts"],"sourcesContent":["import { sentryVitePlugin } from '@sentry/vite-plugin';\nimport type { Plugin, UserConfig } from 'vite';\nimport type { SentrySolidStartPluginOptions } from './types';\n\n/**\n * A Sentry plugin for adding the @sentry/vite-plugin to automatically upload source maps to Sentry.\n */\nexport function makeAddSentryVitePlugin(options: SentrySolidStartPluginOptions, viteConfig: UserConfig): Plugin[] {\n const { authToken, debug, org, project, sourceMapsUploadOptions } = options;\n\n let updatedFilesToDeleteAfterUpload: string[] | undefined = undefined;\n\n if (\n typeof sourceMapsUploadOptions?.filesToDeleteAfterUpload === 'undefined' &&\n typeof sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload ===\n 'undefined' &&\n // Only if source maps were previously not set, we update the \"filesToDeleteAfterUpload\" (as we override the setting with \"hidden\")\n typeof viteConfig.build?.sourcemap === 'undefined'\n ) {\n // For .output, .vercel, .netlify etc.\n updatedFilesToDeleteAfterUpload = ['.*/**/*.map'];\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] Automatically setting \\`sourceMapsUploadOptions.filesToDeleteAfterUpload: ${JSON.stringify(\n updatedFilesToDeleteAfterUpload,\n )}\\` to delete generated source maps after they were uploaded to Sentry.`,\n );\n }\n\n return [\n ...sentryVitePlugin({\n authToken: authToken ?? process.env.SENTRY_AUTH_TOKEN,\n bundleSizeOptimizations: options.bundleSizeOptimizations,\n debug: debug ?? false,\n org: org ?? process.env.SENTRY_ORG,\n project: project ?? process.env.SENTRY_PROJECT,\n sourcemaps: {\n filesToDeleteAfterUpload:\n (sourceMapsUploadOptions?.filesToDeleteAfterUpload ||\n sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload) ??\n updatedFilesToDeleteAfterUpload,\n ...sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps,\n },\n telemetry: sourceMapsUploadOptions?.telemetry ?? true,\n _metaOptions: {\n telemetry: {\n metaFramework: 'solidstart',\n },\n },\n ...sourceMapsUploadOptions?.unstable_sentryVitePluginOptions,\n }),\n ];\n}\n\n/**\n * A Sentry plugin for SolidStart to enable \"hidden\" source maps if they are unset.\n */\nexport function makeEnableSourceMapsVitePlugin(options: SentrySolidStartPluginOptions): Plugin[] {\n return [\n {\n name: 'sentry-solidstart-update-source-map-setting',\n apply: 'build',\n enforce: 'post',\n config(viteConfig) {\n return {\n ...viteConfig,\n build: {\n ...viteConfig.build,\n sourcemap: getUpdatedSourceMapSettings(viteConfig, options),\n },\n };\n },\n },\n ];\n}\n\n/** There are 3 ways to set up source map generation (https://github.com/getsentry/sentry-javascript/issues/13993)\n *\n * 1. User explicitly disabled source maps\n * - keep this setting (emit a warning that errors won't be unminified in Sentry)\n * - We won't upload anything\n *\n * 2. Users enabled source map generation (true, 'hidden', 'inline').\n * - keep this setting (don't do anything - like deletion - besides uploading)\n *\n * 3. Users didn't set source maps generation\n * - we enable 'hidden' source maps generation\n * - configure `filesToDeleteAfterUpload` to delete all .map files (we emit a log about this)\n *\n * --> only exported for testing\n */\nexport function getUpdatedSourceMapSettings(\n viteConfig: UserConfig,\n sentryPluginOptions?: SentrySolidStartPluginOptions,\n): boolean | 'inline' | 'hidden' {\n viteConfig.build = viteConfig.build || {};\n\n const viteSourceMap = viteConfig?.build?.sourcemap;\n let updatedSourceMapSetting = viteSourceMap;\n\n const settingKey = 'vite.build.sourcemap';\n const debug = sentryPluginOptions?.debug;\n\n if (viteSourceMap === false) {\n updatedSourceMapSetting = viteSourceMap;\n\n if (debug) {\n // Longer debug message with more details\n // eslint-disable-next-line no-console\n console.warn(\n `[Sentry] Source map generation is currently disabled in your SolidStart configuration (\\`${settingKey}: false \\`). This setting is either a default setting or was explicitly set in your configuration. Sentry won't override this setting. Without source maps, code snippets on the Sentry Issues page will remain minified. To show unminified code, enable source maps in \\`${settingKey}\\` (e.g. by setting them to \\`hidden\\`).`,\n );\n } else {\n // eslint-disable-next-line no-console\n console.warn('[Sentry] Source map generation is disabled in your SolidStart configuration.');\n }\n } else if (viteSourceMap && ['hidden', 'inline', true].includes(viteSourceMap)) {\n updatedSourceMapSetting = viteSourceMap;\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] We discovered \\`${settingKey}\\` is set to \\`${viteSourceMap.toString()}\\`. Sentry will keep this source map setting. This will un-minify the code snippet on the Sentry Issue page.`,\n );\n } else {\n updatedSourceMapSetting = 'hidden';\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] Enabled source map generation in the build options with \\`${settingKey}: 'hidden'\\`. The source maps will be deleted after they were uploaded to Sentry.`,\n );\n }\n\n return updatedSourceMapSetting;\n}\n"],"names":[],"mappings":";;AAOO,SAAS,uBAAA,CAAwB,SAAwC,UAAA,EAAkC;AAChH,EAAA,MAAM,EAAE,SAAA,EAAW,KAAA,EAAO,GAAA,EAAK,OAAA,EAAS,yBAAwB,GAAI,OAAA;AAEpE,EAAA,IAAI,+BAAA,GAAwD,MAAA;AAE5D,EAAA,IACE,OAAO,yBAAyB,wBAAA,KAA6B,WAAA,IAC7D,OAAO,uBAAA,EAAyB,gCAAA,EAAkC,YAAY,wBAAA,KAC5E,WAAA;AAAA,EAEF,OAAO,UAAA,CAAW,KAAA,EAAO,SAAA,KAAc,WAAA,EACvC;AAEA,IAAA,+BAAA,GAAkC,CAAC,aAAa,CAAA;AAEhD,IAAA,KAAA;AAAA,IAEE,OAAA,CAAQ,GAAA;AAAA,MACN,sFAAsF,IAAA,CAAK,SAAA;AAAA,QACzF;AAAA,OACD,CAAA,sEAAA;AAAA,KACH;AAAA,EACJ;AAEA,EAAA,OAAO;AAAA,IACL,GAAG,gBAAA,CAAiB;AAAA,MAClB,SAAA,EAAW,SAAA,IAAa,OAAA,CAAQ,G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AACnB,EAAA,MAAM,QAAQ,mBAAA,EAAqB,KAAA;AAEnC,EAAA,IAAI,kBAAkB,KAAA,EAAO;AAC3B,IAAA,uBAAA,GAA0B,aAAA;AAE1B,IAAA,IAAI,KAAA,EAAO;AAGT,MAAA,OAAA,CAAQ,IAAA;AAAA,QACN,CAAA,yFAAA,EAA4F,UAAU,CAAA,2QAAA,EAA8Q,UAAU,CAAA,wCAAA;AAAA,OAChY;AAAA,IACF,CAAA,MAAO;AAEL,MAAA,OAAA,CAAQ,KAAK,8EAA8E,CAAA;AAAA,IAC7F;AAAA,EACF,CAAA,MAAA,IAAW,iBAAiB,CAAC,QAAA,EAAU,UAAU,IAAI,CAAA,CAAE,QAAA,CAAS,aAAa,CAAA,EAAG;AAC9E,IAAA,uBAAA,GAA0B,aAAA;AAE1B,IAAA,KAAA;AAAA,IAEE,OAAA,CAAQ,GAAA;AAAA,MACN,CAAA,yBAAA,EAA4B,UAAU,CAAA,eAAA,EAAkB,aAAA,CAAc,UAAU,CAAA,4GAAA;AAAA,KAClF;AAAA,EACJ,CAAA,MAAO;AACL,IAAA,uBAAA,GAA0B,QAAA;AAE1B,IAAA,KAAA;AAAA,IAEE,OAAA,CAAQ,GAAA;AAAA,MACN,sEAAsE,UAAU,CAAA,kFAAA;AAAA,KAClF;AAAA,EACJ;AAEA,EAAA,OAAO,uBAAA;AACT;;;;"}
|
|
1
|
+
{"version":3,"file":"sourceMaps.js","sources":["../../../src/vite/sourceMaps.ts"],"sourcesContent":["import { sentryVitePlugin } from '@sentry/bundler-plugins/vite';\nimport type { Plugin, UserConfig } from 'vite';\nimport type { SentrySolidStartOptions } from './sentrySolidStart';\nimport type { SentrySolidStartPluginOptions } from './types';\n\n// `debug` is all the source map setting logic needs, and all the two majors' option types share.\ntype SourceMapSettingOptions = { debug?: boolean };\n\ntype FilesToDeleteAfterUpload = string | string[] | undefined;\n\n/**\n * A Sentry plugin for adding the @sentry/bundler-plugins/vite plugin to automatically upload source maps to Sentry.\n */\nexport function makeAddSentryVitePlugin(options: SentrySolidStartPluginOptions, viteConfig: UserConfig): Plugin[] {\n const { authToken, debug, org, project, sourceMapsUploadOptions } = options;\n\n let updatedFilesToDeleteAfterUpload: string[] | undefined = undefined;\n\n if (\n typeof sourceMapsUploadOptions?.filesToDeleteAfterUpload === 'undefined' &&\n typeof sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload ===\n 'undefined' &&\n // Only if source maps were previously not set, we update the \"filesToDeleteAfterUpload\" (as we override the setting with \"hidden\")\n typeof viteConfig.build?.sourcemap === 'undefined'\n ) {\n // For .output, .vercel, .netlify etc.\n updatedFilesToDeleteAfterUpload = ['.*/**/*.map'];\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] Automatically setting \\`sourceMapsUploadOptions.filesToDeleteAfterUpload: ${JSON.stringify(\n updatedFilesToDeleteAfterUpload,\n )}\\` to delete generated source maps after they were uploaded to Sentry.`,\n );\n }\n\n return [\n ...sentryVitePlugin({\n authToken: authToken ?? process.env.SENTRY_AUTH_TOKEN,\n bundleSizeOptimizations: options.bundleSizeOptimizations,\n debug: debug ?? false,\n org: org ?? process.env.SENTRY_ORG,\n project: project ?? process.env.SENTRY_PROJECT,\n sourcemaps: {\n filesToDeleteAfterUpload:\n (sourceMapsUploadOptions?.filesToDeleteAfterUpload ||\n sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload) ??\n updatedFilesToDeleteAfterUpload,\n ...sourceMapsUploadOptions?.unstable_sentryVitePluginOptions?.sourcemaps,\n },\n telemetry: sourceMapsUploadOptions?.telemetry ?? true,\n _metaOptions: {\n telemetry: {\n metaFramework: 'solidstart',\n },\n },\n ...sourceMapsUploadOptions?.unstable_sentryVitePluginOptions,\n }),\n ];\n}\n\n/**\n * SolidStart 2 counterpart of `makeAddSentryVitePlugin`, reading the flat `BuildTimeOptionsBase`\n * fields rather than the nested `sourceMapsUploadOptions`.\n *\n * Covers the Vite-built client assets only; Nitro emits the server bundle outside Vite's output dir\n * and the Sentry Nitro module uploads that.\n */\nexport function makeAddSentryVitePluginSolidStart2(options: SentrySolidStartOptions): Plugin[] {\n // Everything not destructured out is field-for-field what `sentryVitePlugin` accepts, so it is\n // spread through — a new shared option then reaches the plugin without editing a list here.\n const {\n authToken,\n buildTimeInstrumentation: _buildTimeInstrumentation,\n debug,\n org,\n project,\n sentryUrl,\n sourcemaps,\n telemetry,\n unstable_sentryVitePluginOptions,\n ...passthroughOptions\n } = options;\n\n // Deferred because the default depends on whether the user set `build.sourcemap` themselves,\n // which is only known once Vite resolves its config. `PromiseLike` because the unstable spelling\n // may itself be a promise.\n let resolveFilesToDeleteAfterUpload:\n | ((value: FilesToDeleteAfterUpload | PromiseLike<FilesToDeleteAfterUpload>) => void)\n | undefined;\n const filesToDeleteAfterUploadPromise = new Promise<FilesToDeleteAfterUpload>(resolve => {\n resolveFilesToDeleteAfterUpload = resolve;\n });\n\n const configPlugin: Plugin = {\n name: 'sentry-solidstart-files-to-delete-after-upload',\n apply: 'build',\n enforce: 'post',\n config(config) {\n // The promise always wins over the passed-in value, so the unstable spelling has to be read\n // here too or it is silently replaced by the default below.\n const userFilesToDelete =\n sourcemaps?.filesToDeleteAfterUpload ?? unstable_sentryVitePluginOptions?.sourcemaps?.filesToDeleteAfterUpload;\n\n // Only clean up source maps we turned on ourselves.\n if (typeof userFilesToDelete === 'undefined' && typeof config.build?.sourcemap === 'undefined') {\n if (debug) {\n // eslint-disable-next-line no-console\n console.log(\n '[Sentry] Automatically setting `sourcemaps.filesToDeleteAfterUpload: [\"./**/*.map\"]` to delete generated source maps after they were uploaded to Sentry.',\n );\n }\n resolveFilesToDeleteAfterUpload?.(['./**/*.map']);\n } else {\n resolveFilesToDeleteAfterUpload?.(userFilesToDelete);\n }\n },\n };\n\n const sentryPlugins = sentryVitePlugin({\n ...passthroughOptions,\n authToken: authToken ?? process.env.SENTRY_AUTH_TOKEN,\n debug: debug ?? false,\n org: org ?? process.env.SENTRY_ORG,\n project: project ?? process.env.SENTRY_PROJECT,\n telemetry: telemetry ?? true,\n url: sentryUrl,\n // Spread here so it overrides the plain options above, but not the objects merged below —\n // spreading replaces whole keys rather than deep-merging.\n ...unstable_sentryVitePluginOptions,\n sourcemaps: {\n ...sourcemaps,\n ...unstable_sentryVitePluginOptions?.sourcemaps,\n filesToDeleteAfterUpload: filesToDeleteAfterUploadPromise,\n },\n _metaOptions: {\n ...unstable_sentryVitePluginOptions?._metaOptions,\n telemetry: {\n ...unstable_sentryVitePluginOptions?._metaOptions?.telemetry,\n metaFramework: 'solidstart',\n },\n },\n });\n\n return [configPlugin, ...sentryPlugins];\n}\n\n/**\n * A Sentry plugin for SolidStart to enable \"hidden\" source maps if they are unset. Used by both\n * SolidStart majors.\n */\nexport function makeEnableSourceMapsVitePlugin(options: SourceMapSettingOptions): Plugin[] {\n return [\n {\n name: 'sentry-solidstart-update-source-map-setting',\n apply: 'build',\n enforce: 'post',\n config(viteConfig) {\n // Return only what changed: Vite concatenates arrays when merging a `config` return value,\n // so echoing the whole config back would duplicate every array the user had.\n return {\n build: {\n sourcemap: getUpdatedSourceMapSettings(viteConfig, options),\n },\n };\n },\n },\n ];\n}\n\n/** There are 3 ways to set up source map generation (https://github.com/getsentry/sentry-javascript/issues/13993)\n *\n * 1. User explicitly disabled source maps\n * - keep this setting (emit a warning that errors won't be unminified in Sentry)\n * - We won't upload anything\n *\n * 2. Users enabled source map generation (true, 'hidden', 'inline').\n * - keep this setting (don't do anything - like deletion - besides uploading)\n *\n * 3. Users didn't set source maps generation\n * - we enable 'hidden' source maps generation\n * - configure `filesToDeleteAfterUpload` to delete all .map files (we emit a log about this)\n *\n * --> only exported for testing\n */\nexport function getUpdatedSourceMapSettings(\n viteConfig: UserConfig,\n sentryPluginOptions?: SourceMapSettingOptions,\n): boolean | 'inline' | 'hidden' {\n const viteSourceMap = viteConfig?.build?.sourcemap;\n let updatedSourceMapSetting = viteSourceMap;\n\n const settingKey = 'vite.build.sourcemap';\n const debug = sentryPluginOptions?.debug;\n\n if (viteSourceMap === false) {\n updatedSourceMapSetting = viteSourceMap;\n\n if (debug) {\n // Longer debug message with more details\n // eslint-disable-next-line no-console\n console.warn(\n `[Sentry] Source map generation is currently disabled in your SolidStart configuration (\\`${settingKey}: false \\`). This setting is either a default setting or was explicitly set in your configuration. Sentry won't override this setting. Without source maps, code snippets on the Sentry Issues page will remain minified. To show unminified code, enable source maps in \\`${settingKey}\\` (e.g. by setting them to \\`hidden\\`).`,\n );\n } else {\n // eslint-disable-next-line no-console\n console.warn('[Sentry] Source map generation is disabled in your SolidStart configuration.');\n }\n } else if (viteSourceMap && ['hidden', 'inline', true].includes(viteSourceMap)) {\n updatedSourceMapSetting = viteSourceMap;\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] We discovered \\`${settingKey}\\` is set to \\`${viteSourceMap.toString()}\\`. Sentry will keep this source map setting. This will un-minify the code snippet on the Sentry Issue page.`,\n );\n } else {\n updatedSourceMapSetting = 'hidden';\n\n debug &&\n // eslint-disable-next-line no-console\n console.log(\n `[Sentry] Enabled source map generation in the build options with \\`${settingKey}: 'hidden'\\`. The source maps will be deleted after they were uploaded to Sentry.`,\n );\n }\n\n return updatedSourceMapSetting;\n}\n"],"names":[],"mappings":";;AAaO,SAAS,uBAAA,CAAwB,SAAwC,UAAA,EAAkC;AAChH,EAAA,MAAM,EAAE,SAAA,EAAW,KAAA,EAAO,GAAA,EAAK,OAAA,EAAS,yBAAwB,GAAI,OAAA;AAEpE,EAAA,IAAI,+BAAA,GAAwD,MAAA;AAE5D,EAAA,IACE,OAAO,yBAAyB,wBAAA,KAA6B,WAAA,IAC7D,OAAO,uBAAA,EAAyB,gCAAA,EAAkC,YAAY,wBAAA,KAC5E,WAAA;AAAA,EAEF,OAAO,UAAA,CAAW,KAAA,EAAO,SAAA,KAAc,WAAA,EACvC;AAEA,IAAA,+BAAA,GAAkC,CAAC,aAAa,CAAA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EAA4B,UAAU,CAAA,eAAA,EAAkB,aAAA,CAAc,UAAU,CAAA,4GAAA;AAAA,KAClF;AAAA,EACJ,CAAA,MAAO;AACL,IAAA,uBAAA,GAA0B,QAAA;AAE1B,IAAA,KAAA;AAAA,IAEE,OAAA,CAAQ,GAAA;AAAA,MACN,sEAAsE,UAAU,CAAA,kFAAA;AAAA,KAClF;AAAA,EACJ;AAEA,EAAA,OAAO,uBAAA;AACT;;;;"}
|
|
@@ -25,7 +25,7 @@ export declare function addSentryTopImport(nitro: Nitro): Promise<void>;
|
|
|
25
25
|
* This function modifies the Rollup configuration to include a plugin that wraps the entry file with a dynamic import (`import()`)
|
|
26
26
|
* and adds the Sentry server config with the static `import` declaration.
|
|
27
27
|
*
|
|
28
|
-
* With this, the Sentry server config can be loaded before all other modules of the application
|
|
28
|
+
* With this, the Sentry server config can be loaded before all other modules of the application.
|
|
29
29
|
* See: https://nodejs.org/api/module.html#enabling
|
|
30
30
|
*/
|
|
31
31
|
export declare function addDynamicImportEntryFileWrapper({ nitro, rollupConfig, sentryPluginOptions, }: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"addInstrumentation.d.ts","sourceRoot":"","sources":["../../../src/config/addInstrumentation.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,WAAW,CAAC;AAEvC,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,eAAe,CAAC;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAI5C,eAAO,MAAM,iBAAiB,UAAmB,CAAC;AAElD,eAAO,MAAM,iBAAiB,UAAc,CAAC;AAE7C;;;;;;;;GAQG;AACH,wBAAsB,6BAA6B,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CA8D/E;AAED;;;;;;GAMG;AACH,wBAAsB,kBAAkB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CA8CpE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
|
-
{"version":3,"file":"withSentry.d.ts","sourceRoot":"","sources":["../../../src/config/withSentry.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"withSentry.d.ts","sourceRoot":"","sources":["../../../src/config/withSentry.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,eAAe,CAAC;AAMnE,OAAO,KAAK,EAAgB,sBAAsB,EAAgC,MAAM,SAAS,CAAC;AAclG;;;;;;;;GAQG;AACH,wBAAgB,UAAU,CACxB,gBAAgB,EAAE,sBAAsB,YAAK,EAC7C,6BAA6B,EAAE,6BAA6B,GAC3D,sBAAsB,CAwExB"}
|
|
@@ -9,7 +9,6 @@ export type WrapServerEntryPluginOptions = {
|
|
|
9
9
|
serverConfigFileName: string;
|
|
10
10
|
resolvedServerConfigPath: string;
|
|
11
11
|
entrypointWrappedFunctions: string[];
|
|
12
|
-
additionalImports?: string[];
|
|
13
12
|
debug?: boolean;
|
|
14
13
|
};
|
|
15
14
|
/**
|
|
@@ -22,7 +21,6 @@ export type WrapServerEntryPluginOptions = {
|
|
|
22
21
|
* @param config.serverEntrypointFileName The server entrypoint (with file extension). Usually, this is defined by the Nitro preset and is something like 'node-server.mjs'
|
|
23
22
|
* @param config.resolvedServerConfigPath Resolved path of the Sentry server config (based on `src` directory)
|
|
24
23
|
* @param config.entryPointWrappedFunctions Exported bindings of the server entry file, which are wrapped as async function. E.g. ['default', 'handler', 'server']
|
|
25
|
-
* @param config.additionalImports Adds additional imports to the entry file. Can be e.g. 'import-in-the-middle/hook.mjs'
|
|
26
24
|
* @param config.debug Whether debug logs are enabled in the build time environment
|
|
27
25
|
*/
|
|
28
26
|
export declare function wrapServerEntryWithDynamicImport(config: WrapServerEntryPluginOptions): InputPluginOption;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wrapServerEntryWithDynamicImport.d.ts","sourceRoot":"","sources":["../../../src/config/wrapServerEntryWithDynamicImport.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAEhD,4GAA4G;AAE5G,eAAO,MAAM,oBAAoB,gCAAgC,CAAC;AAClE,eAAO,MAAM,wBAAwB,qCAAqC,CAAC;AAC3E,eAAO,MAAM,2BAA2B,wCAAwC,CAAC;AACjF,eAAO,MAAM,mBAAmB,qBAAqB,CAAC;AAEtD,MAAM,MAAM,4BAA4B,GAAG;IACzC,wBAAwB,EAAE,MAAM,CAAC;IACjC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,wBAAwB,EAAE,MAAM,CAAC;IACjC,0BAA0B,EAAE,MAAM,EAAE,CAAC;IACrC,
|
|
1
|
+
{"version":3,"file":"wrapServerEntryWithDynamicImport.d.ts","sourceRoot":"","sources":["../../../src/config/wrapServerEntryWithDynamicImport.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAEhD,4GAA4G;AAE5G,eAAO,MAAM,oBAAoB,gCAAgC,CAAC;AAClE,eAAO,MAAM,wBAAwB,qCAAqC,CAAC;AAC3E,eAAO,MAAM,2BAA2B,wCAAwC,CAAC;AACjF,eAAO,MAAM,mBAAmB,qBAAqB,CAAC;AAEtD,MAAM,MAAM,4BAA4B,GAAG;IACzC,wBAAwB,EAAE,MAAM,CAAC;IACjC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,wBAAwB,EAAE,MAAM,CAAC;IACjC,0BAA0B,EAAE,MAAM,EAAE,CAAC;IACrC,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,wBAAgB,gCAAgC,CAAC,MAAM,EAAE,4BAA4B,GAAG,iBAAiB,CAyExG;AAED;;;;;GAKG;AACH,wBAAgB,yBAAyB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAI7D;AAED;;;;;GAKG;AACH,wBAAgB,sCAAsC,CAAC,KAAK,EAAE,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,EAAE,CAAC;IAAC,QAAQ,EAAE,MAAM,EAAE,CAAA;CAAE,CA6B5G;AAED;;;;;;GAMG;AACH,wBAAgB,mCAAmC,CACjD,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,GAAG,IAAI,EACjD,0BAA0B,EAAE,MAAM,EAAE,EACpC,KAAK,CAAC,EAAE,OAAO,GACd,MAAM,CAmCR;AAED;;;;GAIG;AACH,wBAAgB,yBAAyB,CAAC,aAAa,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAsBxF"}
|
|
@@ -9,6 +9,7 @@ export declare function init(options: Options | clientSdk.BrowserOptions | serve
|
|
|
9
9
|
export declare const linkedErrorsIntegration: typeof clientSdk.linkedErrorsIntegration;
|
|
10
10
|
export declare const contextLinesIntegration: typeof clientSdk.contextLinesIntegration;
|
|
11
11
|
export declare const spanStreamingIntegration: typeof clientSdk.spanStreamingIntegration;
|
|
12
|
+
export declare const withStaticSpan: typeof clientSdk.withStaticSpan;
|
|
12
13
|
export declare const withStreamedSpan: typeof clientSdk.withStreamedSpan;
|
|
13
14
|
export declare const getDefaultIntegrations: (options: Options) => Integration[];
|
|
14
15
|
export declare const defaultStackParser: StackParser;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.types.d.ts","sourceRoot":"","sources":["../../src/index.types.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC9E,OAAO,KAAK,KAAK,SAAS,MAAM,UAAU,CAAC;AAC3C,OAAO,KAAK,KAAK,SAAS,MAAM,UAAU,CAAC;AAE3C,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AAEzB,yCAAyC;AACzC,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG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egration, captureEvent, captureException, captureFeedback, captureMessage, captureSession, close,
|
|
1
|
+
export { addBreadcrumb, addEventProcessor, addIntegration, amqplibIntegration, anrIntegration, disableAnrDetectionForCallback, captureCheckIn, captureConsoleIntegration, captureEvent, captureException, captureFeedback, captureMessage, captureSession, close, consoleIntegration, contextLinesIntegration, continueTrace, createGetModuleFromFilename, createTransport, cron, dedupeIntegration, defaultStackParser, endSession, expressErrorHandler, expressIntegration, extraErrorDataIntegration, fastifyIntegration, flush, functionToStringIntegration, genericPoolIntegration, getActiveSpan, getAutoPerformanceIntegrations, getClient, getCurrentScope, getDefaultIntegrations, getGlobalScope, getIsolationScope, getRootSpan, getSentryRelease, getSpanDescendants, getSpanStatusFromHttpCode, graphqlIntegration, hapiIntegration, httpIntegration, httpServerIntegration, httpServerSpansIntegration, eventFiltersIntegration, initOpenTelemetry, isInitialized, isEnabled, knexIntegration, kafkaIntegration, koaIntegration, lastEventId, linkedErrorsIntegration, localVariablesIntegration, makeNodeTransport, modulesIntegration, mongoIntegration, mongooseIntegration, mysql2Integration, mysqlIntegration, nativeNodeFetchIntegration, NodeClient, nodeContextIntegration, onUncaughtExceptionIntegration, onUnhandledRejectionIntegration, parameterize, postgresIntegration, postgresJsIntegration, prismaIntegration, redisIntegration, requestDataIntegration, rewriteFramesIntegration, Scope, SDK_VERSION, SEMANTIC_ATTRIBUTE_SENTRY_OP, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, SEMANTIC_ATTRIBUTE_SENTRY_SAMPLE_RATE, SEMANTIC_ATTRIBUTE_SENTRY_SOURCE, setContext, setCurrentClient, setExtra, setExtras, setHttpStatus, setMeasurement, setTag, setTags, setAttribute, setAttributes, setupExpressErrorHandler, setupHapiErrorHandler, setupKoaErrorHandler, setUser, spanToBaggageHeader, spanToStaticSpanJSON, spanToJSON, spanToTraceHeader, spotlightIntegration, startInactiveSpan, startNewTrace, bindScopeToEmitter, suppressTracing, startSession, startSpan, startSpanManual, tediousIntegration, trpcMiddleware, updateSpanName, withActiveSpan, withIsolationScope, withMonitor, withScope, supabaseIntegration, instrumentSupabaseClient, zodErrorsIntegration, logger, consoleLoggingIntegration, createConsolaReporter, createSentryWinstonTransport, spanStreamingIntegration, withStaticSpan, withStreamedSpan, } from '@sentry/node';
|
|
2
2
|
export * from '@sentry/node';
|
|
3
3
|
export { withSentryErrorBoundary } from '@sentry/solid';
|
|
4
4
|
export { init } from './sdk';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/server/index.ts"],"names":[],"mappings":"AAQA,OAAO,EACL,aAAa,EACb,iBAAiB,EACjB,cAAc,EACd,kBAAkB,EAElB,cAAc,EAEd,8BAA8B,EAC9B,cAAc,EACd,yBAAyB,EACzB,YAAY,EACZ,gBAAgB,EAChB,eAAe,EACf,cAAc,EACd,cAAc,EACd,KAAK,EACL,kBAAkB,EAClB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/server/index.ts"],"names":[],"mappings":"AAQA,OAAO,EACL,aAAa,EACb,iBAAiB,EACjB,cAAc,EACd,kBAAkB,EAElB,cAAc,EAEd,8BAA8B,EAC9B,cAAc,EACd,yBAAyB,EACzB,YAAY,EACZ,gBAAgB,EAChB,eAAe,EACf,cAAc,EACd,cAAc,EACd,KAAK,EACL,kBAAkB,EAClB,uBAAuB,EACvB,aAAa,EACb,2BAA2B,EAC3B,eAAe,EACf,IAAI,EACJ,iBAAiB,EACjB,kBAAkB,EAClB,UAAU,EACV,mBAAmB,EACnB,kBAAkB,EAClB,yBAAyB,EACzB,kBAAkB,EAClB,KAAK,EACL,2BAA2B,EAC3B,sBAAsB,EACtB,aAAa,EACb,8BAA8B,EAC9B,SAAS,EACT,eAAe,EACf,sBAAsB,EACtB,cAAc,EACd,iBAAiB,EACjB,WAAW,EACX,gBAAgB,EAChB,kBAAkB,EAClB,yBAAyB,EACzB,kBAAkB,EAClB,eAAe,EACf,eAAe,EACf,qBAA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|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"middleware.d.ts","sourceRoot":"","sources":["../../../src/server/middleware.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAExD,MAAM,MAAM,0BAA0B,GAAG,UAAU,CAAC,kBAAkB,CAAC,CAAC,CAAC,CAAC,GAAG;IAC3E,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,CAAC;AAaF;;;GAGG;AACH,wBAAgB,8BAA8B,
|
|
1
|
+
{"version":3,"file":"middleware.d.ts","sourceRoot":"","sources":["../../../src/server/middleware.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAExD,MAAM,MAAM,0BAA0B,GAAG,UAAU,CAAC,kBAAkB,CAAC,CAAC,CAAC,CAAC,GAAG;IAC3E,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,CAAC;AAaF;;;GAGG;AACH,wBAAgB,8BAA8B,YACE,UAAU,YAAY,0BAA0B,mBA6B/F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withServerActionInstrumentation.d.ts","sourceRoot":"","sources":["../../../src/server/withServerActionInstrumentation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"withServerActionInstrumentation.d.ts","sourceRoot":"","sources":["../../../src/server/withServerActionInstrumentation.ts"],"names":[],"mappings":"AAYA;;;GAGG;AACH,wBAAsB,+BAA+B,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,EAC7F,gBAAgB,EAAE,MAAM,EACxB,QAAQ,EAAE,CAAC,GACV,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAmDxB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/vite/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,YAAY,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { SentryVitePluginOptions } from '@sentry/bundler-plugins/vite';
|
|
2
|
+
import type { BuildTimeOptionsBase, UnstableVitePluginOptions } from '@sentry/core';
|
|
3
|
+
import type { Plugin } from 'vite';
|
|
4
|
+
/**
|
|
5
|
+
* Build-time options for the Sentry SolidStart SDK on SolidStart 2.
|
|
6
|
+
*/
|
|
7
|
+
export type SentrySolidStartOptions = BuildTimeOptionsBase & UnstableVitePluginOptions<SentryVitePluginOptions>;
|
|
8
|
+
/**
|
|
9
|
+
* Vite plugins for the Sentry SolidStart SDK. Requires SolidStart 2.
|
|
10
|
+
*
|
|
11
|
+
* On SolidStart 1, use `withSentry` in `app.config.ts` instead.
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```typescript
|
|
15
|
+
* // vite.config.ts
|
|
16
|
+
* import { sentrySolidStart } from '@sentry/solidstart/vite';
|
|
17
|
+
* import { solidStart } from '@solidjs/start/config';
|
|
18
|
+
* import { nitro } from 'nitro/vite';
|
|
19
|
+
* import { defineConfig } from 'vite';
|
|
20
|
+
*
|
|
21
|
+
* export default defineConfig({
|
|
22
|
+
* plugins: [
|
|
23
|
+
* solidStart(),
|
|
24
|
+
* sentrySolidStart({
|
|
25
|
+
* org: 'your-org',
|
|
26
|
+
* project: 'your-project',
|
|
27
|
+
* }),
|
|
28
|
+
* nitro(),
|
|
29
|
+
* ],
|
|
30
|
+
* });
|
|
31
|
+
* ```
|
|
32
|
+
*
|
|
33
|
+
* @param options - Options to configure the Sentry Vite plugins
|
|
34
|
+
* @returns An array of Vite plugins
|
|
35
|
+
*/
|
|
36
|
+
export declare function sentrySolidStart(options?: SentrySolidStartOptions): Plugin[];
|
|
37
|
+
//# sourceMappingURL=sentrySolidStart.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sentrySolidStart.d.ts","sourceRoot":"","sources":["../../../src/vite/sentrySolidStart.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAC5E,OAAO,KAAK,EAAE,oBAAoB,EAAE,yBAAyB,EAAE,MAAM,cAAc,CAAC;AAGpF,OAAO,KAAK,EAAE,MAAM,EAAc,MAAM,MAAM,CAAC;AAG/C;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,oBAAoB,GAAG,yBAAyB,CAAC,uBAAuB,CAAC,CAAC;AAEhH;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,GAAE,uBAA4B,GAAG,MAAM,EAAE,CAiBhF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sentrySolidStartVite.d.ts","sourceRoot":"","sources":["../../../src/vite/sentrySolidStartVite.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAG/C,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,oBAAoB,
|
|
1
|
+
{"version":3,"file":"sentrySolidStartVite.d.ts","sourceRoot":"","sources":["../../../src/vite/sentrySolidStartVite.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAG/C,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAC;AAE7D;;GAEG;AACH,eAAO,MAAM,oBAAoB,YAAa,6BAA6B,0BAAmB,UAAU,KAAG,MAAM,EAiBhH,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,qBAAqB,WAAY,UAAU,uBAAgB,6BAA6B,KAAG,UAQvG,CAAC"}
|
|
@@ -1,13 +1,26 @@
|
|
|
1
1
|
import type { Plugin, UserConfig } from 'vite';
|
|
2
|
+
import type { SentrySolidStartOptions } from './sentrySolidStart';
|
|
2
3
|
import type { SentrySolidStartPluginOptions } from './types';
|
|
4
|
+
type SourceMapSettingOptions = {
|
|
5
|
+
debug?: boolean;
|
|
6
|
+
};
|
|
3
7
|
/**
|
|
4
|
-
* A Sentry plugin for adding the @sentry/vite
|
|
8
|
+
* A Sentry plugin for adding the @sentry/bundler-plugins/vite plugin to automatically upload source maps to Sentry.
|
|
5
9
|
*/
|
|
6
10
|
export declare function makeAddSentryVitePlugin(options: SentrySolidStartPluginOptions, viteConfig: UserConfig): Plugin[];
|
|
7
11
|
/**
|
|
8
|
-
*
|
|
12
|
+
* SolidStart 2 counterpart of `makeAddSentryVitePlugin`, reading the flat `BuildTimeOptionsBase`
|
|
13
|
+
* fields rather than the nested `sourceMapsUploadOptions`.
|
|
14
|
+
*
|
|
15
|
+
* Covers the Vite-built client assets only; Nitro emits the server bundle outside Vite's output dir
|
|
16
|
+
* and the Sentry Nitro module uploads that.
|
|
17
|
+
*/
|
|
18
|
+
export declare function makeAddSentryVitePluginSolidStart2(options: SentrySolidStartOptions): Plugin[];
|
|
19
|
+
/**
|
|
20
|
+
* A Sentry plugin for SolidStart to enable "hidden" source maps if they are unset. Used by both
|
|
21
|
+
* SolidStart majors.
|
|
9
22
|
*/
|
|
10
|
-
export declare function makeEnableSourceMapsVitePlugin(options:
|
|
23
|
+
export declare function makeEnableSourceMapsVitePlugin(options: SourceMapSettingOptions): Plugin[];
|
|
11
24
|
/** There are 3 ways to set up source map generation (https://github.com/getsentry/sentry-javascript/issues/13993)
|
|
12
25
|
*
|
|
13
26
|
* 1. User explicitly disabled source maps
|
|
@@ -23,5 +36,6 @@ export declare function makeEnableSourceMapsVitePlugin(options: SentrySolidStart
|
|
|
23
36
|
*
|
|
24
37
|
* --> only exported for testing
|
|
25
38
|
*/
|
|
26
|
-
export declare function getUpdatedSourceMapSettings(viteConfig: UserConfig, sentryPluginOptions?:
|
|
39
|
+
export declare function getUpdatedSourceMapSettings(viteConfig: UserConfig, sentryPluginOptions?: SourceMapSettingOptions): boolean | 'inline' | 'hidden';
|
|
40
|
+
export {};
|
|
27
41
|
//# sourceMappingURL=sourceMaps.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sourceMaps.d.ts","sourceRoot":"","sources":["../../../src/vite/sourceMaps.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAC/C,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"sourceMaps.d.ts","sourceRoot":"","sources":["../../../src/vite/sourceMaps.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAC/C,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAClE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAC;AAG7D,KAAK,uBAAuB,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAInD;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,6BAA6B,EAAE,UAAU,EAAE,UAAU,GAAG,MAAM,EAAE,CA+ChH;AAED;;;;;;GAMG;AACH,wBAAgB,kCAAkC,CAAC,OAAO,EAAE,uBAAuB,GAAG,MAAM,EAAE,CA6E7F;AAED;;;GAGG;AACH,wBAAgB,8BAA8B,CAAC,OAAO,EAAE,uBAAuB,GAAG,MAAM,EAAE,CAiBzF;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,2BAA2B,CACzC,UAAU,EAAE,UAAU,EACtB,mBAAmB,CAAC,EAAE,uBAAuB,GAC5C,OAAO,GAAG,QAAQ,GAAG,QAAQ,CAuC/B"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SentryVitePluginOptions } from '@sentry/vite
|
|
1
|
+
import type { SentryVitePluginOptions } from '@sentry/bundler-plugins/vite';
|
|
2
2
|
type SourceMapsOptions = {
|
|
3
3
|
/**
|
|
4
4
|
* If this flag is `true`, and an auth token is detected, the Sentry SDK will
|
|
@@ -24,7 +24,7 @@ type SourceMapsOptions = {
|
|
|
24
24
|
*/
|
|
25
25
|
filesToDeleteAfterUpload?: string | Array<string>;
|
|
26
26
|
/**
|
|
27
|
-
* Options to further customize the Sentry Vite Plugin (@sentry/vite
|
|
27
|
+
* Options to further customize the Sentry Vite Plugin (@sentry/bundler-plugins/vite) behavior directly.
|
|
28
28
|
* Options specified in this object take precedence over the options specified in
|
|
29
29
|
* the `sourcemaps` and `release` objects.
|
|
30
30
|
*
|
|
@@ -110,6 +110,14 @@ export type SentrySolidStartPluginOptions = {
|
|
|
110
110
|
* Enabling this will give you, for example logs about source maps.
|
|
111
111
|
*/
|
|
112
112
|
debug?: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* Automatic instrumentation of server-side dependencies at build time.
|
|
115
|
+
*
|
|
116
|
+
* Set to `false` to turn it off.
|
|
117
|
+
*
|
|
118
|
+
* @default true
|
|
119
|
+
*/
|
|
120
|
+
buildTimeInstrumentation?: boolean;
|
|
113
121
|
/**
|
|
114
122
|
* The path to your `instrument.server.ts|js` file.
|
|
115
123
|
* e.g. `./src/instrument.server.ts`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/vite/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/vite/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAA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AAsB,CAAC,EAAE,kBAAkB,GAAG,6BAA6B,CAAC;IAE5E;;;;;;;;;;OAUG;IACH,uCAAuC,CAAC,EAAE,MAAM,EAAE,CAAC;CACpD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/solidstart",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "11.0.0-alpha.1",
|
|
4
4
|
"description": "Official Sentry SDK for Solid Start",
|
|
5
5
|
"repository": "git://github.com/getsentry/sentry-javascript.git",
|
|
6
6
|
"homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/solidstart",
|
|
7
7
|
"author": "Sentry",
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"engines": {
|
|
10
|
-
"node": ">=
|
|
10
|
+
"node": ">=20.19.0 <22.0.0 || >=22.12.0 <23.0.0 || >=23.2.0"
|
|
11
11
|
},
|
|
12
12
|
"files": [
|
|
13
13
|
"/build",
|
|
@@ -37,6 +37,10 @@
|
|
|
37
37
|
"node": {
|
|
38
38
|
"import": "./build/esm/index.server.js",
|
|
39
39
|
"require": "./build/cjs/index.server.js"
|
|
40
|
+
},
|
|
41
|
+
"default": {
|
|
42
|
+
"import": "./build/esm/index.server.js",
|
|
43
|
+
"require": "./build/cjs/index.server.js"
|
|
40
44
|
}
|
|
41
45
|
},
|
|
42
46
|
"./solidrouter": {
|
|
@@ -50,7 +54,17 @@
|
|
|
50
54
|
"types": "./solidrouter.d.ts",
|
|
51
55
|
"import": "./build/esm/solidrouter.server.js",
|
|
52
56
|
"require": "./build/cjs/solidrouter.server.js"
|
|
57
|
+
},
|
|
58
|
+
"default": {
|
|
59
|
+
"types": "./solidrouter.d.ts",
|
|
60
|
+
"import": "./build/esm/solidrouter.server.js",
|
|
61
|
+
"require": "./build/cjs/solidrouter.server.js"
|
|
53
62
|
}
|
|
63
|
+
},
|
|
64
|
+
"./vite": {
|
|
65
|
+
"types": "./build/types/vite/index.d.ts",
|
|
66
|
+
"import": "./build/esm/vite/index.js",
|
|
67
|
+
"require": "./build/cjs/vite/index.js"
|
|
54
68
|
}
|
|
55
69
|
},
|
|
56
70
|
"publishConfig": {
|
|
@@ -58,7 +72,7 @@
|
|
|
58
72
|
},
|
|
59
73
|
"peerDependencies": {
|
|
60
74
|
"@solidjs/router": ">=0.13.4 <2.0.0-0",
|
|
61
|
-
"@solidjs/start": "^1.0.0"
|
|
75
|
+
"@solidjs/start": "^1.0.0 || ^2.0.0"
|
|
62
76
|
},
|
|
63
77
|
"peerDependenciesMeta": {
|
|
64
78
|
"@solidjs/router": {
|
|
@@ -66,10 +80,13 @@
|
|
|
66
80
|
}
|
|
67
81
|
},
|
|
68
82
|
"dependencies": {
|
|
69
|
-
"@sentry/core": "
|
|
70
|
-
"@sentry/
|
|
71
|
-
"@sentry/
|
|
72
|
-
"@sentry/
|
|
83
|
+
"@sentry/core": "11.0.0-alpha.1",
|
|
84
|
+
"@sentry/nitro": "11.0.0-alpha.1",
|
|
85
|
+
"@sentry/node": "11.0.0-alpha.1",
|
|
86
|
+
"@sentry/server-utils": "11.0.0-alpha.1",
|
|
87
|
+
"@sentry/solid": "11.0.0-alpha.1",
|
|
88
|
+
"@sentry/bundler-plugins": "11.0.0-alpha.1",
|
|
89
|
+
"@sentry/conventions": "0.19.0"
|
|
73
90
|
},
|
|
74
91
|
"devDependencies": {
|
|
75
92
|
"@solidjs/router": "^1.0.0",
|
|
@@ -95,8 +112,8 @@
|
|
|
95
112
|
"build:tarball": "npm pack",
|
|
96
113
|
"circularDepCheck": "madge --circular src/index.client.ts && madge --circular src/index.server.ts && madge --circular src/index.types.ts && madge --circular src/solidrouter.client.ts && madge --circular src/solidrouter.server.ts && madge --circular src/solidrouter.ts",
|
|
97
114
|
"clean": "rimraf build coverage sentry-solidstart-*.tgz ./*.d.ts ./*.d.ts.map ./client ./server",
|
|
98
|
-
"lint:fix": "
|
|
99
|
-
"lint": "
|
|
115
|
+
"lint:fix": "oxlint . --fix --type-aware",
|
|
116
|
+
"lint": "oxlint . --type-aware",
|
|
100
117
|
"lint:es-compatibility": "es-check es2020 ./build/cjs/*.js && es-check es2020 ./build/esm/*.js --module",
|
|
101
118
|
"test": "yarn test:unit",
|
|
102
119
|
"test:unit": "vitest run",
|