mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-16 23:10:29 +00:00
add parseUser config (#18610)
This commit is contained in:
committed by
Sheetal Nandi
parent
1a77542902
commit
72b910cdf0
Vendored
+3
@@ -62,8 +62,11 @@ export interface ConstructorOptions {
|
||||
transport?(): void;
|
||||
captureUnhandledRejections?: boolean;
|
||||
autoBreadcrumbs?: boolean | any;
|
||||
parseUser?: boolean | string[] | parseUserCallback;
|
||||
}
|
||||
|
||||
export type parseUserCallback = (req: any) => any;
|
||||
|
||||
export interface UserData {
|
||||
id: string;
|
||||
handle?: string;
|
||||
|
||||
@@ -3,6 +3,11 @@ import * as Raven from 'raven';
|
||||
const dsn = '___DSN___';
|
||||
|
||||
const client = Raven.config(dsn, { autoBreadcrumbs: true }).install();
|
||||
Raven.config(dsn, {
|
||||
logger: 'logger',
|
||||
parseUser: ['id', 'name'],
|
||||
autoBreadcrumbs: false,
|
||||
});
|
||||
console.log(Raven.version);
|
||||
Raven.config(dsn).install({ captureUnhandledRejections: true });
|
||||
client.setContext({});
|
||||
|
||||
Reference in New Issue
Block a user