@sentry/wasm 6.18.1 → 6.19.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/package.json +8 -6
- package/rollup.config.js +9 -98
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/wasm",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.19.1",
|
|
4
4
|
"description": "Support for WASM.",
|
|
5
5
|
"repository": "git://github.com/getsentry/sentry-javascript.git",
|
|
6
6
|
"homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/wasm",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"access": "public"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@sentry/browser": "6.
|
|
20
|
-
"@sentry/types": "6.
|
|
19
|
+
"@sentry/browser": "6.19.1",
|
|
20
|
+
"@sentry/types": "6.19.1",
|
|
21
21
|
"tslib": "^1.9.3"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
@@ -29,17 +29,19 @@
|
|
|
29
29
|
"puppeteer": "^5.5.0"
|
|
30
30
|
},
|
|
31
31
|
"scripts": {
|
|
32
|
-
"build": "run-p build:cjs build:esm build:bundle",
|
|
32
|
+
"build": "run-p build:cjs build:esm build:bundle build:types",
|
|
33
33
|
"build:bundle": "rollup --config",
|
|
34
34
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
35
|
-
"build:dev": "run-s build:cjs build:esm",
|
|
35
|
+
"build:dev": "run-s build:cjs build:esm build:types",
|
|
36
36
|
"build:es5": "yarn build:cjs # *** backwards compatibility - remove in v7 ***",
|
|
37
37
|
"build:esm": "tsc -p tsconfig.esm.json",
|
|
38
|
-
"build:
|
|
38
|
+
"build:types": "tsc -p tsconfig.types.json",
|
|
39
|
+
"build:watch": "run-p build:cjs:watch build:esm:watch build:types:watch",
|
|
39
40
|
"build:cjs:watch": "tsc -p tsconfig.cjs.json --watch",
|
|
40
41
|
"build:dev:watch": "run-s build:watch",
|
|
41
42
|
"build:es5:watch": "yarn build:cjs:watch # *** backwards compatibility - remove in v7 ***",
|
|
42
43
|
"build:esm:watch": "tsc -p tsconfig.esm.json --watch",
|
|
44
|
+
"build:types:watch": "tsc -p tsconfig.types.json --watch",
|
|
43
45
|
"circularDepCheck": "madge --circular src/index.ts",
|
|
44
46
|
"clean": "rimraf dist esm coverage *.js.map *.d.ts",
|
|
45
47
|
"fix": "run-s fix:eslint fix:prettier",
|
package/rollup.config.js
CHANGED
|
@@ -1,100 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
// as mangler doesn't touch user-facing thing, however sentryWrapped is not, and it would be mangled into a minified version.
|
|
10
|
-
// We need those full names to correctly detect our internal frames for stripping.
|
|
11
|
-
// I listed all of them here just for the clarity sake, as they are all used in the frames manipulation process.
|
|
12
|
-
reserved: ['captureException', 'captureMessage', 'sentryWrapped'],
|
|
13
|
-
properties: {
|
|
14
|
-
regex: /^_[^_]/,
|
|
15
|
-
},
|
|
16
|
-
},
|
|
17
|
-
output: {
|
|
18
|
-
comments: false,
|
|
19
|
-
},
|
|
1
|
+
import { makeBaseBundleConfig, makeConfigVariants } from '../../rollup.config';
|
|
2
|
+
|
|
3
|
+
const baseBundleConfig = makeBaseBundleConfig({
|
|
4
|
+
input: 'src/index.ts',
|
|
5
|
+
isAddOn: true,
|
|
6
|
+
jsVersion: 'es5',
|
|
7
|
+
licenseTitle: '@sentry/wasm',
|
|
8
|
+
outputFileBase: 'wasm',
|
|
20
9
|
});
|
|
21
10
|
|
|
22
|
-
|
|
23
|
-
typescript({
|
|
24
|
-
tsconfig: 'tsconfig.esm.json',
|
|
25
|
-
tsconfigOverride: {
|
|
26
|
-
compilerOptions: {
|
|
27
|
-
declaration: false,
|
|
28
|
-
declarationMap: false,
|
|
29
|
-
paths: {
|
|
30
|
-
'@sentry/utils': ['../utils/src'],
|
|
31
|
-
'@sentry/core': ['../core/src'],
|
|
32
|
-
'@sentry/hub': ['../hub/src'],
|
|
33
|
-
'@sentry/types': ['../types/src'],
|
|
34
|
-
'@sentry/minimal': ['../minimal/src'],
|
|
35
|
-
},
|
|
36
|
-
baseUrl: '.',
|
|
37
|
-
},
|
|
38
|
-
},
|
|
39
|
-
include: ['*.ts+(|x)', '**/*.ts+(|x)', '../**/*.ts+(|x)'],
|
|
40
|
-
}),
|
|
41
|
-
replace({
|
|
42
|
-
// don't replace `__placeholder__` where it's followed immediately by a single `=` (to prevent ending up
|
|
43
|
-
// with something of the form `let "replacementValue" = "some assigned value"`, which would cause a
|
|
44
|
-
// syntax error)
|
|
45
|
-
preventAssignment: true,
|
|
46
|
-
// the replacements to make
|
|
47
|
-
values: {
|
|
48
|
-
__SENTRY_BROWSER_BUNDLE__: true,
|
|
49
|
-
},
|
|
50
|
-
}),
|
|
51
|
-
resolve({
|
|
52
|
-
mainFields: ['module'],
|
|
53
|
-
}),
|
|
54
|
-
];
|
|
55
|
-
|
|
56
|
-
function mergeIntoSentry() {
|
|
57
|
-
return `
|
|
58
|
-
__window.Sentry = __window.Sentry || {};
|
|
59
|
-
__window.Sentry.Integrations = __window.Sentry.Integrations || {};
|
|
60
|
-
for (var key in exports) {
|
|
61
|
-
if (Object.prototype.hasOwnProperty.call(exports, key)) {
|
|
62
|
-
__window.Sentry.Integrations[key] = exports[key];
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
`;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
function loadAllIntegrations() {
|
|
69
|
-
const builds = [];
|
|
70
|
-
[
|
|
71
|
-
{
|
|
72
|
-
extension: '.js',
|
|
73
|
-
plugins,
|
|
74
|
-
},
|
|
75
|
-
{
|
|
76
|
-
extension: '.min.js',
|
|
77
|
-
plugins: [...plugins, terserInstance],
|
|
78
|
-
},
|
|
79
|
-
].forEach(build => {
|
|
80
|
-
builds.push({
|
|
81
|
-
input: `src/index.ts`,
|
|
82
|
-
output: {
|
|
83
|
-
banner: '(function (__window) {',
|
|
84
|
-
intro: 'var exports = {};',
|
|
85
|
-
outro: mergeIntoSentry(),
|
|
86
|
-
footer: '}(window));',
|
|
87
|
-
file: `build/wasm${build.extension}`,
|
|
88
|
-
format: 'cjs',
|
|
89
|
-
sourcemap: true,
|
|
90
|
-
strict: false,
|
|
91
|
-
esModule: false,
|
|
92
|
-
},
|
|
93
|
-
plugins: build.plugins,
|
|
94
|
-
treeshake: 'smallest',
|
|
95
|
-
});
|
|
96
|
-
});
|
|
97
|
-
return builds;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
export default loadAllIntegrations();
|
|
11
|
+
export default makeConfigVariants(baseBundleConfig);
|