mirror of
https://github.com/tiddly-gittly/TidGi-Desktop.git
synced 2025-12-06 02:30:47 -08:00
fix: some wikiWorker log is very long, cause lagging
This commit is contained in:
parent
d1078ac186
commit
4e28330a9d
6 changed files with 93 additions and 46 deletions
|
|
@ -2,20 +2,10 @@ import { LOG_FOLDER } from '@/constants/appPaths';
|
|||
import winston, { format } from 'winston';
|
||||
import RendererTransport from './rendererTransport';
|
||||
import 'winston-daily-rotate-file';
|
||||
import { levels } from '@/constants/logger';
|
||||
|
||||
export * from './wikiOutput';
|
||||
|
||||
const levels = {
|
||||
emerg: 0,
|
||||
alert: 1,
|
||||
crit: 2,
|
||||
error: 3,
|
||||
warning: 4,
|
||||
warn: 5,
|
||||
notice: 6,
|
||||
info: 7,
|
||||
debug: 8,
|
||||
};
|
||||
export type ILogLevels = keyof typeof levels;
|
||||
const logger = (
|
||||
process.env.NODE_ENV === 'test'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue