Skip to content

Commit b6ae1b3

Browse files
fix the module type
1 parent 506162a commit b6ae1b3

File tree

4 files changed

+259
-3
lines changed

4 files changed

+259
-3
lines changed

packages/lynx-plugin/package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"repository": "https://github.com/getsentry/sentry-lynx",
55
"version": "0.0.0",
66
"description": "Official Sentry Plugin for lynx",
7+
"type": "module",
78
"module": "dist/index.js",
89
"types": "dist/index.d.ts",
910
"exports": {
@@ -36,6 +37,7 @@
3637
"@sentry/webpack-plugin": "3.2.4"
3738
},
3839
"devDependencies": {
40+
"@rsbuild/core": "^1.3.2",
3941
"@types/node": "^20.9.3",
4042
"madge": "^6.1.0",
4143
"npm-run-all2": "^7.0.2",

packages/lynx-plugin/src/index.ts

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,31 @@
1-
export * from '@sentry/webpack-plugin';
1+
import type { RsbuildPlugin } from '@rsbuild/core'
2+
import { sentryWebpackPlugin, type SentryWebpackPluginOptions } from '@sentry/webpack-plugin';
3+
4+
/**
5+
* Create a rsbuild plugin for Sentry Lynx SDK.
6+
*
7+
* @example
8+
* ```ts
9+
* // lynx.config.ts
10+
* import { pluginSentryLynx } from '@sentry/lynx/plugin'
11+
* export default {
12+
* plugins: [pluginSentryLynx({
13+
* org: 'your-organization',
14+
* project: 'your-project',
15+
* authToken: process.env.SENTRY_AUTH_TOKEN,
16+
* })],
17+
* }
18+
* ```
19+
*
20+
* @public
21+
*/
22+
export function pluginSentryLynx(options: SentryWebpackPluginOptions): RsbuildPlugin {
23+
return {
24+
name: 'sentry:rsbuild:lynx',
25+
setup(api) {
26+
api.modifyRspackConfig((config) => {
27+
config.plugins?.push(sentryWebpackPlugin(options));
28+
});
29+
},
30+
}
31+
}

packages/lynx/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"repository": "https://github.com/getsentry/sentry-lynx",
55
"version": "0.0.0",
66
"description": "Official Sentry SDK for lynx",
7+
"type": "module",
78
"module": "dist/index.js",
89
"types": "dist/index.d.ts",
910
"exports": {

yarn.lock

Lines changed: 225 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -580,6 +580,61 @@ __metadata:
580580
languageName: node
581581
linkType: hard
582582

583+
"@module-federation/error-codes@npm:0.11.1":
584+
version: 0.11.1
585+
resolution: "@module-federation/error-codes@npm:0.11.1"
586+
checksum: 10c0/2241dbb047167eedac1993afa3e9407bad1c768cc351b0a646b571450b538fa8b790eedb0fa6014b2bf6ba352df5a55a47326af1a2145137590bfa16b15e1c6e
587+
languageName: node
588+
linkType: hard
589+
590+
"@module-federation/runtime-core@npm:0.11.1":
591+
version: 0.11.1
592+
resolution: "@module-federation/runtime-core@npm:0.11.1"
593+
dependencies:
594+
"@module-federation/error-codes": "npm:0.11.1"
595+
"@module-federation/sdk": "npm:0.11.1"
596+
checksum: 10c0/f300fad95526d743145113542f7e5ac68620bd8278823410b06cbc2337595c2c8d74b7e74ce2a940f3599673223cca7c0611d453a1ce444161743aefe4b7ccc8
597+
languageName: node
598+
linkType: hard
599+
600+
"@module-federation/runtime-tools@npm:0.11.1":
601+
version: 0.11.1
602+
resolution: "@module-federation/runtime-tools@npm:0.11.1"
603+
dependencies:
604+
"@module-federation/runtime": "npm:0.11.1"
605+
"@module-federation/webpack-bundler-runtime": "npm:0.11.1"
606+
checksum: 10c0/d96cd13cf1f9a439fa73492bbcfa15e77f112bed860b6f643fe7b35576a175cfe26c86371bf1074ff757e12fae4e1a1208ba80cc944a2ee19be645ebd88e9e4d
607+
languageName: node
608+
linkType: hard
609+
610+
"@module-federation/runtime@npm:0.11.1":
611+
version: 0.11.1
612+
resolution: "@module-federation/runtime@npm:0.11.1"
613+
dependencies:
614+
"@module-federation/error-codes": "npm:0.11.1"
615+
"@module-federation/runtime-core": "npm:0.11.1"
616+
"@module-federation/sdk": "npm:0.11.1"
617+
checksum: 10c0/d2e756df034a4cb2690f04d4ce1c11fb70eb817f8e9638cb9a350591c0f82acd7fba69afd2752819729766f533b6412f6ce2b7afd50dbeff25569320d666d099
618+
languageName: node
619+
linkType: hard
620+
621+
"@module-federation/sdk@npm:0.11.1":
622+
version: 0.11.1
623+
resolution: "@module-federation/sdk@npm:0.11.1"
624+
checksum: 10c0/d329b8ebf6ba123d35e9656d5c55cfa02cb8d58d37450e8cf0121f727b5a6d4898d3a8921e4522185e64b9150ac0259633785fa3e046cff9451885185b9c10bf
625+
languageName: node
626+
linkType: hard
627+
628+
"@module-federation/webpack-bundler-runtime@npm:0.11.1":
629+
version: 0.11.1
630+
resolution: "@module-federation/webpack-bundler-runtime@npm:0.11.1"
631+
dependencies:
632+
"@module-federation/runtime": "npm:0.11.1"
633+
"@module-federation/sdk": "npm:0.11.1"
634+
checksum: 10c0/335edbfa8129123bddded1ce7a3fc7604b9c5660e41509e429a322400a87c0e91bbb508db71abd8dd9d77e8e470056843bf19181d8972ae954f30dc3f407a37f
635+
languageName: node
636+
linkType: hard
637+
583638
"@napi-rs/wasm-runtime@npm:0.2.4":
584639
version: 0.2.4
585640
resolution: "@napi-rs/wasm-runtime@npm:0.2.4"
@@ -1211,6 +1266,148 @@ __metadata:
12111266
languageName: node
12121267
linkType: hard
12131268

1269+
"@rsbuild/core@npm:^1.3.2":
1270+
version: 1.3.2
1271+
resolution: "@rsbuild/core@npm:1.3.2"
1272+
dependencies:
1273+
"@rspack/core": "npm:1.3.1"
1274+
"@rspack/lite-tapable": "npm:~1.0.1"
1275+
"@swc/helpers": "npm:^0.5.15"
1276+
core-js: "npm:~3.41.0"
1277+
jiti: "npm:^2.4.2"
1278+
bin:
1279+
rsbuild: bin/rsbuild.js
1280+
checksum: 10c0/69070341e531f9ea31e48c39e3cf457220a26b73f8e4e427decc57e236507215e7b615c4278ed97231ec5fb82f2365962537edd272acab3b382bdd674077cb14
1281+
languageName: node
1282+
linkType: hard
1283+
1284+
"@rspack/binding-darwin-arm64@npm:1.3.1":
1285+
version: 1.3.1
1286+
resolution: "@rspack/binding-darwin-arm64@npm:1.3.1"
1287+
conditions: os=darwin & cpu=arm64
1288+
languageName: node
1289+
linkType: hard
1290+
1291+
"@rspack/binding-darwin-x64@npm:1.3.1":
1292+
version: 1.3.1
1293+
resolution: "@rspack/binding-darwin-x64@npm:1.3.1"
1294+
conditions: os=darwin & cpu=x64
1295+
languageName: node
1296+
linkType: hard
1297+
1298+
"@rspack/binding-linux-arm64-gnu@npm:1.3.1":
1299+
version: 1.3.1
1300+
resolution: "@rspack/binding-linux-arm64-gnu@npm:1.3.1"
1301+
conditions: os=linux & cpu=arm64 & libc=glibc
1302+
languageName: node
1303+
linkType: hard
1304+
1305+
"@rspack/binding-linux-arm64-musl@npm:1.3.1":
1306+
version: 1.3.1
1307+
resolution: "@rspack/binding-linux-arm64-musl@npm:1.3.1"
1308+
conditions: os=linux & cpu=arm64 & libc=musl
1309+
languageName: node
1310+
linkType: hard
1311+
1312+
"@rspack/binding-linux-x64-gnu@npm:1.3.1":
1313+
version: 1.3.1
1314+
resolution: "@rspack/binding-linux-x64-gnu@npm:1.3.1"
1315+
conditions: os=linux & cpu=x64 & libc=glibc
1316+
languageName: node
1317+
linkType: hard
1318+
1319+
"@rspack/binding-linux-x64-musl@npm:1.3.1":
1320+
version: 1.3.1
1321+
resolution: "@rspack/binding-linux-x64-musl@npm:1.3.1"
1322+
conditions: os=linux & cpu=x64 & libc=musl
1323+
languageName: node
1324+
linkType: hard
1325+
1326+
"@rspack/binding-win32-arm64-msvc@npm:1.3.1":
1327+
version: 1.3.1
1328+
resolution: "@rspack/binding-win32-arm64-msvc@npm:1.3.1"
1329+
conditions: os=win32 & cpu=arm64
1330+
languageName: node
1331+
linkType: hard
1332+
1333+
"@rspack/binding-win32-ia32-msvc@npm:1.3.1":
1334+
version: 1.3.1
1335+
resolution: "@rspack/binding-win32-ia32-msvc@npm:1.3.1"
1336+
conditions: os=win32 & cpu=ia32
1337+
languageName: node
1338+
linkType: hard
1339+
1340+
"@rspack/binding-win32-x64-msvc@npm:1.3.1":
1341+
version: 1.3.1
1342+
resolution: "@rspack/binding-win32-x64-msvc@npm:1.3.1"
1343+
conditions: os=win32 & cpu=x64
1344+
languageName: node
1345+
linkType: hard
1346+
1347+
"@rspack/binding@npm:1.3.1":
1348+
version: 1.3.1
1349+
resolution: "@rspack/binding@npm:1.3.1"
1350+
dependencies:
1351+
"@rspack/binding-darwin-arm64": "npm:1.3.1"
1352+
"@rspack/binding-darwin-x64": "npm:1.3.1"
1353+
"@rspack/binding-linux-arm64-gnu": "npm:1.3.1"
1354+
"@rspack/binding-linux-arm64-musl": "npm:1.3.1"
1355+
"@rspack/binding-linux-x64-gnu": "npm:1.3.1"
1356+
"@rspack/binding-linux-x64-musl": "npm:1.3.1"
1357+
"@rspack/binding-win32-arm64-msvc": "npm:1.3.1"
1358+
"@rspack/binding-win32-ia32-msvc": "npm:1.3.1"
1359+
"@rspack/binding-win32-x64-msvc": "npm:1.3.1"
1360+
dependenciesMeta:
1361+
"@rspack/binding-darwin-arm64":
1362+
optional: true
1363+
"@rspack/binding-darwin-x64":
1364+
optional: true
1365+
"@rspack/binding-linux-arm64-gnu":
1366+
optional: true
1367+
"@rspack/binding-linux-arm64-musl":
1368+
optional: true
1369+
"@rspack/binding-linux-x64-gnu":
1370+
optional: true
1371+
"@rspack/binding-linux-x64-musl":
1372+
optional: true
1373+
"@rspack/binding-win32-arm64-msvc":
1374+
optional: true
1375+
"@rspack/binding-win32-ia32-msvc":
1376+
optional: true
1377+
"@rspack/binding-win32-x64-msvc":
1378+
optional: true
1379+
checksum: 10c0/5e3c8cfa6750d50321857e3ef37303b9648ac31ffdfca3e2f46919733191df51b38710646c64e81a391786aea51200f9b314fcb38e650f40edd9fe427a678265
1380+
languageName: node
1381+
linkType: hard
1382+
1383+
"@rspack/core@npm:1.3.1":
1384+
version: 1.3.1
1385+
resolution: "@rspack/core@npm:1.3.1"
1386+
dependencies:
1387+
"@module-federation/runtime-tools": "npm:0.11.1"
1388+
"@rspack/binding": "npm:1.3.1"
1389+
"@rspack/lite-tapable": "npm:1.0.1"
1390+
caniuse-lite: "npm:^1.0.30001706"
1391+
tinypool: "npm:^1.0.2"
1392+
peerDependencies:
1393+
"@rspack/tracing": ^1.x
1394+
"@swc/helpers": ">=0.5.1"
1395+
peerDependenciesMeta:
1396+
"@rspack/tracing":
1397+
optional: true
1398+
"@swc/helpers":
1399+
optional: true
1400+
checksum: 10c0/e3af19aa5e78ef129934f6253d16abef010ca59a31cac3d9778aa635ce00f899f9f3f963d0b261c7949eb7c8d993d25dc760659ddd3c6ebc6ed7007df7a82a21
1401+
languageName: node
1402+
linkType: hard
1403+
1404+
"@rspack/lite-tapable@npm:1.0.1, @rspack/lite-tapable@npm:~1.0.1":
1405+
version: 1.0.1
1406+
resolution: "@rspack/lite-tapable@npm:1.0.1"
1407+
checksum: 10c0/90bb1bc414dc51ea2d0933e09f78d25584f3f50a85f4cb8228930bd29e5931bf55eff4f348a06c51dd3149fc73b8ae3920bf0ae5ae8a0c9fe1d9b404e6ecf5b7
1408+
languageName: node
1409+
linkType: hard
1410+
12141411
"@rtsao/scc@npm:^1.1.0":
12151412
version: 1.1.0
12161413
resolution: "@rtsao/scc@npm:1.1.0"
@@ -1266,6 +1463,7 @@ __metadata:
12661463
version: 0.0.0-use.local
12671464
resolution: "@sentry-internal/lynx-plugin@workspace:packages/lynx-plugin"
12681465
dependencies:
1466+
"@rsbuild/core": "npm:^1.3.2"
12691467
"@sentry/webpack-plugin": "npm:3.2.4"
12701468
"@types/node": "npm:^20.9.3"
12711469
madge: "npm:^6.1.0"
@@ -1528,6 +1726,15 @@ __metadata:
15281726
languageName: node
15291727
linkType: hard
15301728

1729+
"@swc/helpers@npm:^0.5.15":
1730+
version: 0.5.15
1731+
resolution: "@swc/helpers@npm:0.5.15"
1732+
dependencies:
1733+
tslib: "npm:^2.8.0"
1734+
checksum: 10c0/33002f74f6f885f04c132960835fdfc474186983ea567606db62e86acd0680ca82f34647e8e610f4e1e422d1c16fce729dde22cd3b797ab1fd9061a825dabca4
1735+
languageName: node
1736+
linkType: hard
1737+
15311738
"@tufjs/canonical-json@npm:2.0.0":
15321739
version: 2.0.0
15331740
resolution: "@tufjs/canonical-json@npm:2.0.0"
@@ -2455,7 +2662,7 @@ __metadata:
24552662
languageName: node
24562663
linkType: hard
24572664

2458-
"caniuse-lite@npm:^1.0.30001688":
2665+
"caniuse-lite@npm:^1.0.30001688, caniuse-lite@npm:^1.0.30001706":
24592666
version: 1.0.30001707
24602667
resolution: "caniuse-lite@npm:1.0.30001707"
24612668
checksum: 10c0/a1beaf84bad4f6617bbc5616d6bc0c9cab73e73f7e9e09b6466af5195b1bc393e0f6f19643d7a1c88bd3f4bfa122d7bea81cf6225ec3ade57d5b1dd3478c1a1b
@@ -2862,6 +3069,13 @@ __metadata:
28623069
languageName: node
28633070
linkType: hard
28643071

3072+
"core-js@npm:~3.41.0":
3073+
version: 3.41.0
3074+
resolution: "core-js@npm:3.41.0"
3075+
checksum: 10c0/a29ed0b7fe81acf49d04ce5c17a1947166b1c15197327a5d12f95bbe84b46d60c3c13de701d808f41da06fa316285f3f55ce5903abc8d5642afc1eac4457afc8
3076+
languageName: node
3077+
linkType: hard
3078+
28653079
"core-util-is@npm:~1.0.0":
28663080
version: 1.0.3
28673081
resolution: "core-util-is@npm:1.0.3"
@@ -5317,6 +5531,15 @@ __metadata:
53175531
languageName: node
53185532
linkType: hard
53195533

5534+
"jiti@npm:^2.4.2":
5535+
version: 2.4.2
5536+
resolution: "jiti@npm:2.4.2"
5537+
bin:
5538+
jiti: lib/jiti-cli.mjs
5539+
checksum: 10c0/4ceac133a08c8faff7eac84aabb917e85e8257f5ad659e843004ce76e981c457c390a220881748ac67ba1b940b9b729b30fb85cbaf6e7989f04b6002c94da331
5540+
languageName: node
5541+
linkType: hard
5542+
53205543
"js-tokens@npm:^4.0.0":
53215544
version: 4.0.0
53225545
resolution: "js-tokens@npm:4.0.0"
@@ -8709,7 +8932,7 @@ __metadata:
87098932
languageName: node
87108933
linkType: hard
87118934

8712-
"tslib@npm:^2.1.0, tslib@npm:^2.3.0, tslib@npm:^2.3.1, tslib@npm:^2.4.0":
8935+
"tslib@npm:^2.1.0, tslib@npm:^2.3.0, tslib@npm:^2.3.1, tslib@npm:^2.4.0, tslib@npm:^2.8.0":
87138936
version: 2.8.1
87148937
resolution: "tslib@npm:2.8.1"
87158938
checksum: 10c0/9c4759110a19c53f992d9aae23aac5ced636e99887b51b9e61def52611732872ff7668757d4e4c61f19691e36f4da981cd9485e869b4a7408d689f6bf1f14e62

0 commit comments

Comments
 (0)