refactor: Use ESM (#8358)
* wip * wip * fix * clean up * Update tsconfig.json * Update activitypub.ts * wip
This commit is contained in:
parent
0a882471f3
commit
d071d18dd7
737 changed files with 4135 additions and 3678 deletions
|
|
@ -1,8 +1,9 @@
|
|||
import * as cluster from 'cluster';
|
||||
import * as chalk from 'chalk';
|
||||
import cluster from 'node:cluster';
|
||||
import chalk from 'chalk';
|
||||
import { default as convertColor } from 'color-convert';
|
||||
import { format as dateFormat } from 'date-fns';
|
||||
import { envOption } from '../env';
|
||||
import config from '@/config/index';
|
||||
import { envOption } from '../env.js';
|
||||
import config from '@/config/index.js';
|
||||
|
||||
import * as SyslogPro from 'syslog-pro';
|
||||
|
||||
|
|
@ -66,7 +67,7 @@ export default class Logger {
|
|||
level === 'debug' ? chalk.gray('VERB') :
|
||||
level === 'info' ? chalk.blue('INFO') :
|
||||
null;
|
||||
const domains = [this.domain].concat(subDomains).map(d => d.color ? chalk.keyword(d.color)(d.name) : chalk.white(d.name));
|
||||
const domains = [this.domain].concat(subDomains).map(d => d.color ? chalk.rgb(...convertColor.keyword.rgb(d.color))(d.name) : chalk.white(d.name));
|
||||
const m =
|
||||
level === 'error' ? chalk.red(message) :
|
||||
level === 'warning' ? chalk.yellow(message) :
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue