From 759d93dc198a3cc8c5265245c0144efa5435682b Mon Sep 17 00:00:00 2001 From: Vijay Aravamudhan Date: Fri, 22 Apr 2022 15:04:21 -0500 Subject: Turn off usage of 'debug' npm package using with electron-16 (fixes #17) --- src/webview/darkmode.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/webview/darkmode.ts') diff --git a/src/webview/darkmode.ts b/src/webview/darkmode.ts index fbb0edf04..99ee68757 100644 --- a/src/webview/darkmode.ts +++ b/src/webview/darkmode.ts @@ -1,7 +1,8 @@ import { join } from 'path'; import { pathExistsSync, readFileSync } from 'fs-extra'; -const debug = require('debug')('Ferdium:DarkMode'); +// TODO: Go back to 'debug' from 'console.log' when https://github.com/electron/electron/issues/31689 is fixed +// const debug = require('debug')('Ferdium:DarkMode'); const chars = [...'abcdefghijklmnopqrstuvwxyz']; @@ -26,7 +27,7 @@ export function injectDarkModeStyle(recipePath: string) { document.querySelector('head')?.appendChild(styles); - debug('Injected Dark Mode style with ID', ID); + console.log('Injected Dark Mode style with ID', ID); } } @@ -36,7 +37,7 @@ export function removeDarkModeStyle() { if (style) { style.remove(); - debug('Removed Dark Mode Style with ID', ID); + console.log('Removed Dark Mode Style with ID', ID); } } -- cgit v1.2.3-70-g09d2