如何在 Node JS 的 Chalk 中增加字体大小?我想用我的代码做到这一点。这显然是英格兰国旗,但我想在下面添加一些文字,说它要回家了。不知道看过很多 gits 和论坛,但找不到任何已经问过的东西。
const chalk = new require('chalk').constructor({ enabled: true, level: 3 });
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.red.bgRed
('...........................') +
chalk.red.bgRed('2222222') +
chalk.red.bgRed('...........................')
);
console.log(
chalk.red.bgRed
('...........................') +
chalk.red.bgRed('2222222') +
chalk.red.bgRed('...........................')
);
console.log(
chalk.red.bgRed
('...........................') +
chalk.red.bgRed('2222222') +
chalk.red.bgRed('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);
console.log(
chalk.white.bgWhite
('...........................') +
chalk.red.bgRed('2222222') +
chalk.white.bgWhite('...........................')
);