Giant blob of minor changes
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / loglevel / index.d.ts
index b049831664c24cfac6d050d2bb142b47d46bf411..3ff4da5a3468f3ae23c9b78e5a5d900d728fc91d 100644 (file)
@@ -39,7 +39,7 @@ declare namespace log {
 
     type LoggingMethod = (...message: any[]) => void;
 
-    type MethodFactory = (methodName: string, level: LogLevelNumbers, loggerName: string) => LoggingMethod;
+    type MethodFactory = (methodName: string, level: LogLevelNumbers, loggerName: string | symbol) => LoggingMethod;
 
     interface RootLogger extends Logger {
         /**
@@ -52,8 +52,8 @@ declare namespace log {
 
         /**
          * This gets you a new logger object that works exactly like the root log object, but can have its level and
-         * logging methods set independently. All loggers must have a name (which is a non-empty string). Calling
-         * getLogger() multiple times with the same name will return an identical logger object.
+         * logging methods set independently. All loggers must have a name (which is a non-empty string or a symbol)
+         * Calling * getLogger() multiple times with the same name will return an identical logger object.
          * In large applications, it can be incredibly useful to turn logging on and off for particular modules as you are
          * working with them. Using the getLogger() method lets you create a separate logger for each part of your
          * application with its own logging level. Likewise, for small, independent modules, using a named logger instead
@@ -62,12 +62,17 @@ declare namespace log {
          * circumstances.
          * @param name The name of the produced logger
          */
-        getLogger(name: string): Logger;
+        getLogger(name: string | symbol): Logger;
 
         /**
          * This will return you the dictionary of all loggers created with getLogger, keyed off of their names.
          */
         getLoggers(): { [name: string]: Logger };
+
+        /**
+         * A .default property for ES6 default import compatibility
+         */
+        default: RootLogger;
     }
 
     interface Logger {