Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
nicohrubec committed Jul 3, 2024
1 parent cef0a49 commit b297c41
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions packages/nestjs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,23 @@ Sentry.init({

Note that it is necessary to initialize Sentry **before you import any package that may be instrumented by us**.

## Span Decorator

Use the @GetSentrySpan() decorator to gain additional performance insights for any function within your NestJS application.

```js
import { Injectable } from '@nestjs/common';
import { GetSentrySpan } from '@sentry/nestjs';

@Injectable()
export class ExampleService {
@GetSentrySpan()
async performTask() {
// Your business logic here
}
}
```

## Links

- [Official SDK Docs](https://docs.sentry.io/platforms/javascript/guides/nestjs/)

0 comments on commit b297c41

Please sign in to comment.