File tree 2 files changed +9
-1
lines changed
2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -366,6 +366,13 @@ export const _experiment_log = {
366
366
* Ex: Sentry._experiment_log.info`user ${username} just bought ${item}!`
367
367
*/
368
368
info : sendLog . bind ( null , 'info' ) as OmitFirstArg < typeof sendLog > ,
369
+ /**
370
+ * A utility to record a log with level 'INFO' and send it to sentry.
371
+ *
372
+ * Logs represent a message and some parameters which provide context for a trace or error.
373
+ * Ex: Sentry._experiment_log.log`user ${username} just bought ${item}!`
374
+ */
375
+ log : sendLog . bind ( null , 'log' ) as OmitFirstArg < typeof sendLog > ,
369
376
/**
370
377
* A utility to record a log with level 'ERROR' and send it to sentry.
371
378
*
Original file line number Diff line number Diff line change @@ -13,8 +13,9 @@ let GLOBAL_LOG_BUFFER: Log[] = [];
13
13
14
14
let isFlushingLogs = false ;
15
15
16
- const SEVERITY_TEXT_TO_SEVERITY_NUMBER : Partial < Record < LogSeverityLevel , number > > = {
16
+ const SEVERITY_TEXT_TO_SEVERITY_NUMBER : Partial < Record < LogSeverityLevel | 'log' , number > > = {
17
17
trace : 1 ,
18
+ log : 2 ,
18
19
debug : 5 ,
19
20
info : 9 ,
20
21
warn : 13 ,
You can’t perform that action at this time.
0 commit comments