1+ import type { BuildTimeOptionsBase } from '@sentry/core' ;
12import type { init as initNode } from '@sentry/node' ;
23import type { SentryRollupPluginOptions } from '@sentry/rollup-plugin' ;
34import type { SentryVitePluginOptions } from '@sentry/vite-plugin' ;
@@ -26,6 +27,7 @@ type SourceMapsOptions = {
2627 * Suppresses all logs.
2728 *
2829 * @default false
30+ * @deprecated Use option `silent` instead of `sourceMapsUploadOptions.silent`
2931 */
3032 silent ?: boolean ;
3133
@@ -43,13 +45,17 @@ type SourceMapsOptions = {
4345 * console.warn(err);
4446 * }
4547 * ```
48+ *
49+ * @deprecated Use option `errorHandler` instead of `sourceMapsUploadOptions.errorHandler`
4650 */
4751 errorHandler ?: ( err : Error ) => void ;
4852
4953 /**
5054 * Options related to managing the Sentry releases for a build.
5155 *
5256 * More info: https://docs.sentry.io/product/releases/
57+ *
58+ * @deprecated Use option `release` instead of `sourceMapsUploadOptions.release`
5359 */
5460 release ?: {
5561 /**
@@ -62,6 +68,8 @@ type SourceMapsOptions = {
6268 * (the latter requires access to git CLI and for the root directory to be a valid repository)
6369 *
6470 * If you didn't provide a value and the plugin can't automatically detect one, no release will be created.
71+ *
72+ * @deprecated Use `release.name` instead of `sourceMapsUploadOptions.release.name`
6573 */
6674 name ?: string ;
6775 } ;
@@ -71,6 +79,7 @@ type SourceMapsOptions = {
7179 * automatically generate and upload source maps to Sentry during a production build.
7280 *
7381 * @default true
82+ * @deprecated Use option `sourcemaps.disable` instead of `sourceMapsUploadOptions.enabled`
7483 */
7584 enabled ?: boolean ;
7685
@@ -81,25 +90,30 @@ type SourceMapsOptions = {
8190 *
8291 * To create an auth token, follow this guide:
8392 * @see https://docs.sentry.io/product/accounts/auth-tokens/#organization-auth-tokens
93+ * @deprecated Use option `authToken` instead of `sourceMapsUploadOptions.authToken`
8494 */
8595 authToken ?: string ;
8696
8797 /**
8898 * The organization slug of your Sentry organization.
8999 * Instead of specifying this option, you can also set the `SENTRY_ORG` environment variable.
100+ * @deprecated Use option `org` instead of `sourceMapsUploadOptions.org`
90101 */
91102 org ?: string ;
92103
93104 /**
94105 * The URL of your Sentry instance if you're using self-hosted Sentry.
95106 *
96107 * @default https://sentry.io by default the plugin will point towards the Sentry SaaS URL
108+ * @deprecated Use `sentryUrl` instead of `sourceMapsUploadOptions.url`
97109 */
98110 url ?: string ;
99111
100112 /**
101113 * The project slug of your Sentry project.
102114 * Instead of specifying this option, you can also set the `SENTRY_PROJECT` environment variable.
115+ *
116+ * @deprecated Use option `project` instead of `sourceMapsUploadOptions.project`
103117 */
104118 project ?: string ;
105119
@@ -108,11 +122,14 @@ type SourceMapsOptions = {
108122 * It will not collect any sensitive or user-specific data.
109123 *
110124 * @default true
125+ * @deprecated Use option `telemetry` instead of `sourceMapsUploadOptions.telemetry`
111126 */
112127 telemetry ?: boolean ;
113128
114129 /**
115130 * Options related to sourcemaps
131+ *
132+ * @deprecated Use option `sourcemaps` instead of `sourceMapsUploadOptions.sourcemaps`
116133 */
117134 sourcemaps ?: {
118135 /**
@@ -124,6 +141,8 @@ type SourceMapsOptions = {
124141 *
125142 * The globbing patterns must follow the implementation of the `glob` package.
126143 * @see https://www.npmjs.com/package/glob#glob-primer
144+ *
145+ * @deprecated Use option `sourcemaps.assets` instead of `sourceMapsUploadOptions.sourcemaps.assets`
127146 */
128147 assets ?: string | Array < string > ;
129148
@@ -134,6 +153,8 @@ type SourceMapsOptions = {
134153 * or the default value for `assets` are uploaded.
135154 *
136155 * The globbing patterns follow the implementation of the glob package. (https://www.npmjs.com/package/glob)
156+ *
157+ * @deprecated Use option `sourcemaps.ignore` instead of `sourceMapsUploadOptions.sourcemaps.ignore`
137158 */
138159 ignore ?: string | Array < string > ;
139160
@@ -144,6 +165,8 @@ type SourceMapsOptions = {
144165 * @default [] - By default no files are deleted.
145166 *
146167 * The globbing patterns follow the implementation of the glob package. (https://www.npmjs.com/package/glob)
168+ *
169+ * @deprecated Use option `sourcemaps.filesToDeleteAfterUpload` instead of `sourceMapsUploadOptions.sourcemaps.filesToDeleteAfterUpload`
147170 */
148171 filesToDeleteAfterUpload ?: string | Array < string > ;
149172 } ;
@@ -152,7 +175,7 @@ type SourceMapsOptions = {
152175/**
153176 * Build options for the Sentry module. These options are used during build-time by the Sentry SDK.
154177 */
155- export type SentryNuxtModuleOptions = {
178+ export type SentryNuxtModuleOptions = BuildTimeOptionsBase & {
156179 /**
157180 * Enable the Sentry Nuxt Module.
158181 *
@@ -165,15 +188,12 @@ export type SentryNuxtModuleOptions = {
165188 *
166189 * These options are always read from the `sentry` module options in the `nuxt.config.(js|ts).
167190 * Do not define them in the `sentry.client.config.(js|ts)` or `sentry.server.config.(js|ts)` files.
191+ *
192+ * @deprecated This option was deprecated as it adds unnecessary nesting.
193+ * Put the options one level higher to the root-level of the `sentry` module options.
168194 */
169195 sourceMapsUploadOptions ?: SourceMapsOptions ;
170196
171- /**
172- * Enable debug functionality of the SDK during build-time.
173- * Enabling this will give you, for example, logs about source maps.
174- */
175- debug ?: boolean ;
176-
177197 /**
178198 *
179199 * Enables (partial) server tracing by automatically injecting Sentry for environments where modifying the node option `--import` is not possible.
0 commit comments