File tree Expand file tree Collapse file tree 4 files changed +6
-4
lines changed
dev-packages/rollup-utils/plugins Expand file tree Collapse file tree 4 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ export function makeIsDebugBuildPlugin(includeDebugging) {
5252export function makeSetSDKSourcePlugin ( sdkSource ) {
5353 return replacePlugin (
5454 {
55- '/* __SENTRY_SDK_SOURCE__ */' : `return ${ JSON . stringify ( sdkSource ) } ;` ,
55+ '/*! __SENTRY_SDK_SOURCE__ */' : `return ${ JSON . stringify ( sdkSource ) } ;` ,
5656 } ,
5757 {
5858 preventAssignment : false ,
Original file line number Diff line number Diff line change @@ -207,8 +207,8 @@ function replaceSDKSource(): void {
207207 // Replace the line marked with __SENTRY_SDK_SOURCE__ comment
208208 // Change from 'npm' to 'aws-lambda-layer' to identify that this is the AWS Lambda layer
209209 content = content . replace (
210- "/* __SENTRY_SDK_SOURCE__ */ return ' npm';" ,
211- "/* __SENTRY_SDK_SOURCE__ */ return ' aws-lambda-layer';" ,
210+ '/*! __SENTRY_SDK_SOURCE__ */ return " npm";' ,
211+ '/*! __SENTRY_SDK_SOURCE__ */ return " aws-lambda-layer";' ,
212212 ) ;
213213
214214 fs . writeFileSync ( envFile , content ) ;
Original file line number Diff line number Diff line change @@ -31,5 +31,5 @@ export function isBrowserBundle(): boolean {
3131 */
3232export function getSDKSource ( ) : SdkSource {
3333 // This comment is used to identify this line in the CDN bundle build step and replace this with "return 'cdn';"
34- /* __SENTRY_SDK_SOURCE__ */ return 'npm' ;
34+ /*! __SENTRY_SDK_SOURCE__ */ return 'npm' ;
3535}
Original file line number Diff line number Diff line change @@ -236,6 +236,8 @@ module.exports = {
236236 balanced : true ,
237237 // ... unless they're jsdoc-style block comments, which end with `**/`
238238 exceptions : [ '*' ] ,
239+ // Allow /*! for legal/preserved comments
240+ markers : [ '!' ] ,
239241 } ,
240242 } ,
241243 ] ,
You can’t perform that action at this time.
0 commit comments