Skip to content

Commit

Permalink
Fix logging in browsers
Browse files Browse the repository at this point in the history
  • Loading branch information
spalladino committed Apr 9, 2024
1 parent 1d4cb0d commit 850b6b3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion yarn-project/foundation/src/log/logger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ function getPrefix(debugLogger: debug.Debugger, level: LogLevel) {
* @param msg - What to log.
*/
function printLog(msg: string) {
process.stderr.write(msg + '\n');
// eslint-disable-next-line no-console
isNode ? process.stderr.write(msg + '\n') : console.error(msg);
}

/**
Expand Down

0 comments on commit 850b6b3

Please sign in to comment.