@athenna/logger 3.0.9 → 3.1.0

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.
Files changed (85) hide show
  1. package/build/Drivers/ConsoleDriver.d.ts +12 -0
  2. package/build/Drivers/ConsoleDriver.js +19 -0
  3. package/build/Drivers/DiscordDriver.d.ts +12 -0
  4. package/build/Drivers/DiscordDriver.js +22 -0
  5. package/build/Drivers/Driver.d.ts +52 -0
  6. package/build/Drivers/Driver.js +85 -0
  7. package/build/Drivers/FileDriver.d.ts +12 -0
  8. package/build/Drivers/FileDriver.js +24 -0
  9. package/build/Drivers/NullDriver.d.ts +12 -0
  10. package/build/Drivers/NullDriver.js +14 -0
  11. package/build/Drivers/SlackDriver.d.ts +12 -0
  12. package/build/Drivers/SlackDriver.js +19 -0
  13. package/build/Drivers/StackDriver.d.ts +12 -0
  14. package/build/Drivers/StackDriver.js +19 -0
  15. package/build/Drivers/TelegramDriver.d.ts +12 -0
  16. package/build/Drivers/TelegramDriver.js +21 -0
  17. package/build/Exceptions/DriverExistException.d.ts +12 -0
  18. package/build/Exceptions/DriverExistException.js +21 -0
  19. package/{src/Facades/Log.js → build/Exceptions/FormatterExistException.d.ts} +4 -9
  20. package/build/Exceptions/FormatterExistException.js +21 -0
  21. package/build/Exceptions/NotFoundDriverException.d.ts +12 -0
  22. package/build/Exceptions/NotFoundDriverException.js +21 -0
  23. package/build/Exceptions/NotFoundFormatterException.d.ts +12 -0
  24. package/build/Exceptions/NotFoundFormatterException.js +21 -0
  25. package/build/Exceptions/NotImplementedConfigException.d.ts +12 -0
  26. package/build/Exceptions/NotImplementedConfigException.js +28 -0
  27. package/build/Facades/Log.d.ts +10 -0
  28. package/build/Facades/Log.js +10 -0
  29. package/build/Factories/DriverFactory.d.ts +39 -0
  30. package/build/Factories/DriverFactory.js +93 -0
  31. package/build/Factories/FormatterFactory.d.ts +29 -0
  32. package/build/Factories/FormatterFactory.js +57 -0
  33. package/build/Formatters/CliFormatter.d.ts +12 -0
  34. package/build/Formatters/CliFormatter.js +15 -0
  35. package/build/Formatters/Formatter.d.ts +85 -0
  36. package/build/Formatters/Formatter.js +177 -0
  37. package/build/Formatters/JsonFormatter.d.ts +12 -0
  38. package/build/Formatters/JsonFormatter.js +26 -0
  39. package/build/Formatters/MessageFormatter.d.ts +12 -0
  40. package/build/Formatters/MessageFormatter.js +14 -0
  41. package/build/Formatters/NoneFormatter.d.ts +12 -0
  42. package/{src → build}/Formatters/NoneFormatter.js +4 -12
  43. package/build/Formatters/RequestFormatter.d.ts +12 -0
  44. package/build/Formatters/RequestFormatter.js +45 -0
  45. package/build/Formatters/SimpleFormatter.d.ts +12 -0
  46. package/build/Formatters/SimpleFormatter.js +18 -0
  47. package/build/Helpers/ColorHelper.d.ts +131 -0
  48. package/build/Helpers/ColorHelper.js +215 -0
  49. package/build/Helpers/FactoryHelper.d.ts +14 -0
  50. package/build/Helpers/FactoryHelper.js +20 -0
  51. package/build/Logger/Logger.d.ts +68 -0
  52. package/build/Logger/Logger.js +105 -0
  53. package/build/Logger/VanillaLogger.d.ts +60 -0
  54. package/build/Logger/VanillaLogger.js +86 -0
  55. package/build/Providers/LoggerProvider.d.ts +12 -0
  56. package/{src → build}/Providers/LoggerProvider.js +5 -12
  57. package/build/index.d.ts +18 -0
  58. package/build/index.js +18 -0
  59. package/package.json +81 -59
  60. package/src/Drivers/ConsoleDriver.js +0 -40
  61. package/src/Drivers/DiscordDriver.js +0 -43
  62. package/src/Drivers/Driver.js +0 -134
  63. package/src/Drivers/FileDriver.js +0 -47
  64. package/src/Drivers/NullDriver.js +0 -33
  65. package/src/Drivers/SlackDriver.js +0 -40
  66. package/src/Drivers/StackDriver.js +0 -45
  67. package/src/Drivers/TelegramDriver.js +0 -46
  68. package/src/Exceptions/DriverExistException.js +0 -31
  69. package/src/Exceptions/FormatterExistException.js +0 -32
  70. package/src/Exceptions/NotFoundDriverException.js +0 -31
  71. package/src/Exceptions/NotFoundFormatterException.js +0 -31
  72. package/src/Exceptions/NotImplementedConfigException.js +0 -37
  73. package/src/Factories/DriverFactory.js +0 -128
  74. package/src/Factories/FormatterFactory.js +0 -77
  75. package/src/Formatters/CliFormatter.js +0 -24
  76. package/src/Formatters/Formatter.js +0 -266
  77. package/src/Formatters/JsonFormatter.js +0 -37
  78. package/src/Formatters/MessageFormatter.js +0 -26
  79. package/src/Formatters/RequestFormatter.js +0 -64
  80. package/src/Formatters/SimpleFormatter.js +0 -27
  81. package/src/Helpers/ColorHelper.js +0 -322
  82. package/src/Helpers/FactoryHelper.js +0 -31
  83. package/src/Helpers/VanillaLogger.js +0 -134
  84. package/src/index.d.ts +0 -797
  85. package/src/index.js +0 -180
package/src/index.d.ts DELETED
@@ -1,797 +0,0 @@
1
- /**
2
- * @athenna/logger
3
- *
4
- * (c) João Lenon <lenon@athenna.io>
5
- *
6
- * For the full copyright and license information, please view the LICENSE
7
- * file that was distributed with this source code.
8
- */
9
-
10
- import { Facade } from '@athenna/ioc'
11
- import { Options } from '@athenna/common'
12
-
13
- export const Log: typeof Facade & Logger
14
-
15
- export class Driver {
16
- /**
17
- * Holds the configuration object itself.
18
- *
19
- * @type {any}
20
- */
21
- configs: any
22
-
23
- /**
24
- * Holds the configuration object of driver.
25
- *
26
- * @type {any}
27
- */
28
- driverConfig: any
29
-
30
- /**
31
- * Holds the formatter string value.
32
- *
33
- * @type {string}
34
- */
35
- formatter: string
36
-
37
- /**
38
- * Holds the configuration object of formatter.
39
- *
40
- * @type {any}
41
- */
42
- formatterConfig: any
43
-
44
- /**
45
- * The max log level that this driver can transport.
46
- *
47
- * @return {string}
48
- */
49
- level: string
50
-
51
- /**
52
- * The log level order to check if log could
53
- * be transported or not.
54
- *
55
- * @type {string[]}
56
- */
57
- levelOrder: string[]
58
-
59
- /**
60
- * Creates a new instance of ConsoleDriver.
61
- *
62
- * @param {any} configs
63
- * @return {Driver}
64
- */
65
- constructor(configs: any)
66
-
67
- /**
68
- * Transport the log.
69
- *
70
- * @param {string} level
71
- * @param {string} message
72
- * @return {any | Promise<any>}
73
- */
74
- transport(level: string, message: string): any | Promise<any>
75
-
76
- /**
77
- * Check if message could be transported.
78
- *
79
- * @param level {string}
80
- * @return {boolean}
81
- */
82
- couldBeTransported(level: string): boolean
83
-
84
- /**
85
- * Call formatter factory to format the message.
86
- *
87
- * @param level {string}
88
- * @param message {string}
89
- * @param [clean] {boolean}
90
- * @return {any}
91
- */
92
- format(level: string, message: string, clean?: boolean): any
93
-
94
- /**
95
- * Get the stream type for level.
96
- *
97
- * @param level {string}
98
- * @return {string}
99
- */
100
- getStreamTypeFor(level: string): string
101
- }
102
-
103
- export class Formatter {
104
- /**
105
- * Holds the configuration object of formatter.
106
- */
107
- configs: any
108
-
109
- /**
110
- * Creates a new instance of Formatter.
111
- *
112
- * @param {any} configs
113
- * @return {Formatter}
114
- */
115
- config(configs: any): Formatter
116
-
117
- /**
118
- * Format the message.
119
- *
120
- * @param {string} message
121
- * @return {string}
122
- */
123
- format(message: string): string
124
-
125
- /**
126
- * Create the PID for formatter.
127
- *
128
- * @return {string}
129
- */
130
- pid(): string
131
-
132
- /**
133
- * Create the hostname for formatter.
134
- *
135
- * @return {string}
136
- */
137
- hostname(): string
138
-
139
- /**
140
- * Get the level without any color or format.
141
- *
142
- * @return {string}
143
- */
144
- level(): string
145
-
146
- /**
147
- * Get the trace id for formatter.
148
- *
149
- * @return {string | null}
150
- */
151
- traceId(): string | null
152
-
153
- /**
154
- * Create the timestamp for formatter.
155
- *
156
- * @return {string}
157
- */
158
- timestamp(): string
159
-
160
- /**
161
- * Transform the message to string.
162
- *
163
- * @param message {string}
164
- * @return {string}
165
- */
166
- toString(message: string): string
167
-
168
- /**
169
- * Clean the message removing colors if clean
170
- * option is true. If force is true, then colors
171
- * will be removed even if configs clean option
172
- * is false.
173
- *
174
- * @param message {string}
175
- * @param [force] {boolean}
176
- * @return {string}
177
- */
178
- clean(message, force?: boolean): string
179
-
180
- /**
181
- * Apply all colors necessary to message.
182
- *
183
- * @param message {string}
184
- * @return {string}
185
- */
186
- applyColors(message: string): string
187
-
188
- /**
189
- * Apply colors in message.
190
- *
191
- * @param message {string}
192
- * @return {string}
193
- */
194
- applyColorsByChalk(message: string): string
195
-
196
- /**
197
- * Apply colors in message by level.
198
- *
199
- * @param message {string}
200
- * @return {string}
201
- */
202
- applyColorsByLevel(message: string): string
203
-
204
- /**
205
- * Create the cli level string.
206
- *
207
- * @return {string}
208
- */
209
- cliLevel(): string
210
-
211
- /**
212
- * Create the simple level string.
213
- *
214
- * @return {string}
215
- */
216
- simpleLevel(): string
217
-
218
- /**
219
- * Create the message level emoji string.
220
- *
221
- * @return {string}
222
- */
223
- messageLevel(): string
224
- }
225
-
226
- export class ColorHelper {
227
- /**
228
- * Chalk instance.
229
- *
230
- * @return {import('chalk').ChalkInstance}
231
- */
232
- static chalk: import('chalk').ChalkInstance
233
-
234
- /**
235
- * Paint as bold.
236
- *
237
- * @return {import('chalk').ChalkInstance}
238
- */
239
- static get bold(): import('chalk').ChalkInstance
240
-
241
- /**
242
- * Paint as purple.
243
- *
244
- * @return {import('chalk').ChalkInstance}
245
- */
246
- static get purple(): import('chalk').ChalkInstance
247
-
248
- /**
249
- * Paint as darkPurple.
250
- *
251
- * @return {import('chalk').ChalkInstance}
252
- */
253
- static get darkPurple(): import('chalk').ChalkInstance
254
-
255
- /**
256
- * Paint as yellow.
257
- *
258
- * @return {import('chalk').ChalkInstance}
259
- */
260
- static get yellow(): import('chalk').ChalkInstance
261
-
262
- /**
263
- * Paint as cyan.
264
- *
265
- * @return {import('chalk').ChalkInstance}
266
- */
267
- static get cyan(): import('chalk').ChalkInstance
268
-
269
- /**
270
- * Paint as white.
271
- *
272
- * @return {import('chalk').ChalkInstance}
273
- */
274
- static get white(): import('chalk').ChalkInstance
275
-
276
- /**
277
- * Paint as orange.
278
- *
279
- * @return {import('chalk').ChalkInstance}
280
- */
281
- static get orange(): import('chalk').ChalkInstance
282
-
283
- /**
284
- * Paint as green.
285
- *
286
- * @return {import('chalk').ChalkInstance}
287
- */
288
- static get green(): import('chalk').ChalkInstance
289
-
290
- /**
291
- * Paint as darkGreen.
292
- *
293
- * @return {import('chalk').ChalkInstance}
294
- */
295
- static get darkGreen(): import('chalk').ChalkInstance
296
-
297
- /**
298
- * Paint as red.
299
- *
300
- * @return {import('chalk').ChalkInstance}
301
- */
302
- static get red(): import('chalk').ChalkInstance
303
-
304
- /**
305
- * Paint traces.
306
- *
307
- * @return {import('chalk').ChalkInstance}
308
- */
309
- static get trace(): import('chalk').ChalkInstance
310
-
311
- /**
312
- * Paint debugs.
313
- *
314
- * @return {import('chalk').ChalkInstance}
315
- */
316
- static get debug(): import('chalk').ChalkInstance
317
-
318
- /**
319
- * Paint infos.
320
- *
321
- * @return {import('chalk').ChalkInstance}
322
- */
323
- static get info(): import('chalk').ChalkInstance
324
-
325
- /**
326
- * Paint success.
327
- *
328
- * @return {import('chalk').ChalkInstance}
329
- */
330
- static get success(): import('chalk').ChalkInstance
331
-
332
- /**
333
- * Paint warns.
334
- *
335
- * @return {import('chalk').ChalkInstance}
336
- */
337
- static get warn(): import('chalk').ChalkInstance
338
-
339
- /**
340
- * Paint errors.
341
- *
342
- * @return {import('chalk').ChalkInstance}
343
- */
344
- static get error(): import('chalk').ChalkInstance
345
-
346
- /**
347
- * Paint fatals.
348
- *
349
- * @return {import('chalk').ChalkInstance}
350
- */
351
- static get fatal(): import('chalk').ChalkInstance
352
-
353
- /**
354
- * Paint http method.
355
- *
356
- * @return {import('chalk').ChalkInstance}
357
- */
358
- static get GET(): import('chalk').ChalkInstance
359
-
360
- /**
361
- * Paint http method.
362
- *
363
- * @return {import('chalk').ChalkInstance}
364
- */
365
- static get HEAD(): import('chalk').ChalkInstance
366
-
367
- /**
368
- * Paint http method.
369
- *
370
- * @return {import('chalk').ChalkInstance}
371
- */
372
- static get PUT(): import('chalk').ChalkInstance
373
-
374
- /**
375
- * Paint http method.
376
- *
377
- * @return {import('chalk').ChalkInstance}
378
- */
379
- static get PATCH(): import('chalk').ChalkInstance
380
-
381
- /**
382
- * Paint http method.
383
- *
384
- * @return {import('chalk').ChalkInstance}
385
- */
386
- static get POST(): import('chalk').ChalkInstance
387
-
388
- /**
389
- * Paint http method.
390
- *
391
- * @return {import('chalk').ChalkInstance}
392
- */
393
- static get DELETE(): import('chalk').ChalkInstance
394
-
395
- /**
396
- * Paint http method.
397
- *
398
- * @return {import('chalk').ChalkInstance}
399
- */
400
- static get OPTIONS(): import('chalk').ChalkInstance
401
-
402
- /**
403
- * Remove all colors and special chars of string.
404
- *
405
- * @param {string} string
406
- * @return {string}
407
- */
408
- static removeColors(string: string): string
409
-
410
- /**
411
- * Paint by the http method.
412
- *
413
- * @param {'GET' | 'POST' | 'PUT' | 'DELETE' | 'PATCH', 'OPTIONS', 'HEAD' } method
414
- * @return {import('chalk').ChalkInstance}
415
- */
416
- static httpMethod(method: any): import('chalk').ChalkInstance
417
-
418
- /**
419
- * Applies the log engine to execute chalk methods.
420
- *
421
- * @param {string} args
422
- * @return {any}
423
- */
424
- static applyLogEngine(...args): any
425
- }
426
-
427
- export class FactoryHelper {
428
- /**
429
- * Group the configuration values.
430
- *
431
- * @param {any} object
432
- * @param {any} defaultValue
433
- * @return {any}
434
- */
435
- static groupConfigs(object: any, defaultValue: any): any
436
- }
437
-
438
- export class DriverFactory {
439
- /**
440
- * Drivers of DriverFactory.
441
- *
442
- * @type {Map<string, { Driver: any }>}
443
- */
444
- static drivers: Map<
445
- string,
446
- {
447
- Driver: any
448
- }
449
- >
450
-
451
- /**
452
- * Return an array with all available drivers.
453
- *
454
- * @return {any[]}
455
- */
456
- static availableDrivers(): any[]
457
-
458
- /**
459
- * Fabricate a new instance of a driver based on
460
- * channel configurations.
461
- *
462
- * @param {string} channelName
463
- * @param {any} runtimeConfig
464
- * @return {any}
465
- */
466
- static fabricate(channelName: string, runtimeConfig?: any): any
467
-
468
- /**
469
- * Fabricate a new instance of a driver with vanilla
470
- * configurations.
471
- *
472
- * @param {any} configs
473
- * @return {any}
474
- */
475
- static fabricateVanilla(configs?: any): any
476
-
477
- /**
478
- * Creates a new driver implementation.
479
- *
480
- * @param {string} name
481
- * @param {(channel: string, configs?: any) => any} driver
482
- */
483
- static createDriver(
484
- name: string,
485
- driver: (channel: string, configs?: any) => any,
486
- ): void
487
- }
488
-
489
- export class FormatterFactory {
490
- /**
491
- * Formatters of FormatterFactory.
492
- *
493
- * @type {Map<string, { Formatter: any }>}
494
- */
495
- static formatters: Map<
496
- string,
497
- {
498
- Formatter: any
499
- }
500
- >
501
-
502
- /**
503
- * Return an array with all available formatters.
504
- *
505
- * @return {any[]}
506
- */
507
- static availableFormatters(): any[]
508
-
509
- /**
510
- * Fabricate a new instance of a formatter.
511
- *
512
- * @param {string} formatterName
513
- * @return {any}
514
- */
515
- static fabricate(formatterName: string): any
516
-
517
- /**
518
- * Creates a new formatter implementation.
519
- *
520
- * @param {string} name
521
- * @param {() => any} formatter
522
- */
523
- static createFormatter(name: string, formatter: () => any): void
524
- }
525
-
526
- export class VanillaLogger {
527
- /**
528
- * Set runtime configurations for drivers and
529
- * formatters.
530
- *
531
- * @param {any} runtimeConfig
532
- * @return {VanillaLogger}
533
- */
534
- config(runtimeConfig: any): VanillaLogger
535
-
536
- /**
537
- * Change the log channel.
538
- *
539
- * @param {string[]} channels
540
- * @return {VanillaLogger}
541
- */
542
- channel(...channels: string[]): VanillaLogger
543
-
544
- /**
545
- * Creates a log of type trace in channel.
546
- *
547
- * @param {string|any} message
548
- * @return {any | Promise<any>}
549
- */
550
- trace(message: string | any): any | Promise<any>
551
-
552
- /**
553
- * Creates a log of type trace in channel.
554
- *
555
- * @param {string[]|any[]} args
556
- * @return {any | Promise<any>}
557
- */
558
- trace(...args: string[] | any[]): any | Promise<any>
559
-
560
- /**
561
- * Creates a log of type debug in channel.
562
- *
563
- * @param {string|any} message
564
- * @return {any | Promise<any>}
565
- */
566
- debug(message: string | any): any | Promise<any>
567
-
568
- /**
569
- * Creates a log of type debug in channel.
570
- *
571
- * @param {string[]|any[]} args
572
- * @return {any | Promise<any>}
573
- */
574
- debug(...args: string[] | any[]): any | Promise<any>
575
-
576
- /**
577
- * Creates a log of type info in channel.
578
- *
579
- * @param {string|any} message
580
- * @return {any | Promise<any>}
581
- */
582
- info(message: string | any): any | Promise<any>
583
-
584
- /**
585
- * Creates a log of type info in channel.
586
- *
587
- * @param {string[]|any[]} args
588
- * @return {any | Promise<any>}
589
- */
590
- info(...args: string[] | any[]): any | Promise<any>
591
-
592
- /**
593
- * Creates a log of type success in channel.
594
- *
595
- * @param {string|any} message
596
- * @return {any | Promise<any>}
597
- */
598
- success(message: string | any): any | Promise<any>
599
-
600
- /**
601
- * Creates a log of type success in channel.
602
- *
603
- * @param {string[]|any[]} args
604
- * @return {any | Promise<any>}
605
- */
606
- success(...args: string[] | any[]): any | Promise<any>
607
-
608
- /**
609
- * Creates a log of type warn in channel.
610
- *
611
- * @param {string|any} message
612
- * @return {any | Promise<any>}
613
- */
614
- warn(message: string | any): any | Promise<any>
615
-
616
- /**
617
- * Creates a log of type warn in channel.
618
- *
619
- * @param {string[]|any[]} args
620
- * @return {any | Promise<any>}
621
- */
622
- warn(...args: string[] | any[]): any | Promise<any>
623
-
624
- /**
625
- * Creates a log of type error in channel.
626
- *
627
- * @param {string|any} message
628
- * @return {any | Promise<any>}
629
- */
630
- error(message: string | any): any | Promise<any>
631
-
632
- /**
633
- * Creates a log of type error in channel.
634
- *
635
- * @param {string[]|any[]} args
636
- * @return {any | Promise<any>}
637
- */
638
- error(...args: string[] | any[]): any | Promise<any>
639
-
640
- /**
641
- * Creates a log of type fatal in channel.
642
- *
643
- * @param {string|any} message
644
- * @return {any | Promise<any>}
645
- */
646
- fatal(message: string | any): any | Promise<any>
647
-
648
- /**
649
- * Creates a log of type fatal in channel.
650
- *
651
- * @param {string[]|any[]} args
652
- * @return {any | Promise<any>}
653
- */
654
- fatal(...args: string[] | any[]): any | Promise<any>
655
- }
656
-
657
- export class Logger {
658
- /**
659
- * Set runtime configurations for drivers and
660
- * formatters.
661
- *
662
- * @param {any} runtimeConfig
663
- * @return {Logger}
664
- */
665
- config(runtimeConfig: any): Logger
666
-
667
- /**
668
- * Change the log channel.
669
- *
670
- * @param {string[]} channels
671
- * @return {Logger}
672
- */
673
- channel(...channels: string[]): Logger
674
-
675
- /**
676
- * Creates a log of type trace in channel.
677
- *
678
- * @param {string|any} message
679
- * @return {any | Promise<any>}
680
- */
681
- trace(message: string | any): any | Promise<any>
682
-
683
- /**
684
- * Creates a log of type trace in channel.
685
- *
686
- * @param {string[]|any[]} args
687
- * @return {any | Promise<any>}
688
- */
689
- trace(...args: string[] | any[]): any | Promise<any>
690
-
691
- /**
692
- * Creates a log of type debug in channel.
693
- *
694
- * @param {string|any} message
695
- * @return {any | Promise<any>}
696
- */
697
- debug(message: string | any): any | Promise<any>
698
-
699
- /**
700
- * Creates a log of type debug in channel.
701
- *
702
- * @param {string[]|any[]} args
703
- * @return {any | Promise<any>}
704
- */
705
- debug(...args: string[] | any[]): any | Promise<any>
706
-
707
- /**
708
- * Creates a log of type info in channel.
709
- *
710
- * @param {string|any} message
711
- * @return {any | Promise<any>}
712
- */
713
- info(message: string | any): any | Promise<any>
714
-
715
- /**
716
- * Creates a log of type info in channel.
717
- *
718
- * @param {string[]|any[]} args
719
- * @return {any | Promise<any>}
720
- */
721
- info(...args: string[] | any[]): any | Promise<any>
722
-
723
- /**
724
- * Creates a log of type success in channel.
725
- *
726
- * @param {string|any} message
727
- * @return {any | Promise<any>}
728
- */
729
- success(message: string | any): any | Promise<any>
730
-
731
- /**
732
- * Creates a log of type success in channel.
733
- *
734
- * @param {string[]|any[]} args
735
- * @return {any | Promise<any>}
736
- */
737
- success(...args: string[] | any[]): any | Promise<any>
738
-
739
- /**
740
- * Creates a log of type warn in channel.
741
- *
742
- * @param {string|any} message
743
- * @return {any | Promise<any>}
744
- */
745
- warn(message: string | any): any | Promise<any>
746
-
747
- /**
748
- * Creates a log of type warn in channel.
749
- *
750
- * @param {string[]|any[]} args
751
- * @return {any | Promise<any>}
752
- */
753
- warn(...args: string[] | any[]): any | Promise<any>
754
-
755
- /**
756
- * Creates a log of type error in channel.
757
- *
758
- * @param {string|any} message
759
- * @return {any | Promise<any>}
760
- */
761
- error(message: string | any): any | Promise<any>
762
-
763
- /**
764
- * Creates a log of type error in channel.
765
- *
766
- * @param {string[]|any[]} args
767
- * @return {any | Promise<any>}
768
- */
769
- error(...args: string[] | any[]): any | Promise<any>
770
-
771
- /**
772
- * Creates a log of type fatal in channel.
773
- *
774
- * @param {string|any} message
775
- * @return {any | Promise<any>}
776
- */
777
- fatal(message: string | any): any | Promise<any>
778
-
779
- /**
780
- * Creates a log of type fatal in channel.
781
- *
782
- * @param {string[]|any[]} args
783
- * @return {any | Promise<any>}
784
- */
785
- fatal(...args: string[] | any[]): any | Promise<any>
786
-
787
- /**
788
- * Get a new instance of any log driver
789
- * with vanilla configurations. By default,
790
- * vanilla logger will use the "console" driver
791
- * and "none" formatter.
792
- *
793
- * @param {any} [configs]
794
- * @return {VanillaLogger}
795
- */
796
- static getVanillaLogger(configs?: any): VanillaLogger
797
- }