@lowerdeck/sentry 1.0.0 → 1.0.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/.turbo/turbo-build.log +10 -9
- package/CHANGELOG.md +7 -0
- package/README.md +48 -0
- package/package.json +1 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
|
|
2
2
|
[0m[2m[35m$[0m [2m[1mmicrobundle[0m
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
3
|
+
No name was provided for external module '@sentry/core' in output.globals – guessing 'SentryBase'
|
|
4
|
+
[34mBuild "@lowerdeck/sentry" to dist:[39m
|
|
5
|
+
[32m272 B[39m: [37mindex.cjs[39m.gz
|
|
6
|
+
[32m219 B[39m: [37mindex.cjs[39m.br
|
|
7
|
+
[32m117 B[39m: [37mindex.module.js[39m.gz
|
|
8
|
+
[32m95 B[39m: [37mindex.module.js[39m.br
|
|
9
|
+
[32m127 B[39m: [37mindex.module.js[39m.gz
|
|
10
|
+
[32m96 B[39m: [37mindex.module.js[39m.br
|
|
11
|
+
[32m366 B[39m: [37mindex.umd.js[39m.gz
|
|
12
|
+
[32m308 B[39m: [37mindex.umd.js[39m.br
|
package/CHANGELOG.md
ADDED
package/README.md
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# `@lowerdeck/sentry`
|
|
2
|
+
|
|
3
|
+
Lightweight wrapper for managing Sentry instances across your application. Provides a global reference that can be configured and accessed throughout your codebase.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @lowerdeck/sentry
|
|
9
|
+
yarn add @lowerdeck/sentry
|
|
10
|
+
bun add @lowerdeck/sentry
|
|
11
|
+
pnpm add @lowerdeck/sentry
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Usage
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import { setSentry, getSentry } from '@lowerdeck/sentry';
|
|
18
|
+
import * as Sentry from '@sentry/node';
|
|
19
|
+
|
|
20
|
+
// Initialize Sentry in your application
|
|
21
|
+
Sentry.init({
|
|
22
|
+
dsn: 'your-dsn-here',
|
|
23
|
+
environment: 'production'
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
// Set the Sentry instance
|
|
27
|
+
setSentry(Sentry);
|
|
28
|
+
|
|
29
|
+
// Access Sentry from anywhere in your application
|
|
30
|
+
const sentry = getSentry();
|
|
31
|
+
sentry.captureException(new Error('Something went wrong'));
|
|
32
|
+
|
|
33
|
+
// In other modules
|
|
34
|
+
import { getSentry } from '@lowerdeck/sentry';
|
|
35
|
+
|
|
36
|
+
function logError(error: Error) {
|
|
37
|
+
const sentry = getSentry();
|
|
38
|
+
sentry.captureException(error);
|
|
39
|
+
}
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## License
|
|
43
|
+
|
|
44
|
+
This project is licensed under the Apache License 2.0.
|
|
45
|
+
|
|
46
|
+
<div align="center">
|
|
47
|
+
<sub>Built with ❤️ by <a href="https://metorial.com">Metorial</a></sub>
|
|
48
|
+
</div>
|