ProjextWebpackUtils
This is a set of utility methods the Projext webpack plugins use.
Static Method Summary
Static Public Methods | ||
public static |
createLogger(plugin: string, logger: Logger): Logger Validate and create a Logger instance for a plugin. |
Static Public Methods
public static createLogger(plugin: string, logger: Logger): Logger source
Validate and create a Logger instance for a plugin. If the logger the plugin received on its options is an instance of Logger or has the same interface, it will "accept it" and return it; If the plugin didn't receive a logger, it will create a new instance of Logger and return it, but if the received logger is an invalid object, it will throw an error.