
Research
/Security News
Malicious Chrome and Firefox Extensions Steal Crypto Traders’ Session and Wallet Data
Malicious Chrome and Firefox extensions target Axiom Trade and Padre users, stealing session tokens and wallet data.
Yanse (颜色) - Fast terminal color styling
Fast and lightweight terminal color styling library with a chalk-like API. Yanse (颜色, yánsè) means "color" in Chinese.
Why? We got tired of chalk's ESM-only errors and needed control over our dependencies. This utility is too simple to justify depending on chalk and wrestling with module: true.
npm install yanse
import yanse, { red, green, blue, yellow, cyan } from 'yanse';
console.log(red('Error message'));
console.log(green('Success message'));
console.log(blue('Info message'));
console.log(yellow('Warning message'));
console.log(cyan('Debug message'));
import yanse from 'yanse';
console.log(yanse.bold.red('Bold red text'));
console.log(yanse.bold.yellow.italic('Bold yellow italic text'));
console.log(yanse.green.bold.underline('Bold green underlined text'));
import { yellow, red, cyan } from 'yanse';
console.log(yellow(`foo ${red.bold('red')} bar ${cyan('cyan')} baz`));
Perfect for building loggers with colored output:
import yanse, { cyan, yellow, red, green, bold } from 'yanse';
type LogLevel = 'info' | 'warn' | 'error' | 'debug' | 'success';
const levelColors: Record<LogLevel, typeof cyan> = {
info: cyan,
warn: yellow,
error: red,
debug: yanse.gray,
success: green
};
class Logger {
constructor(private scope: string) {}
log(level: LogLevel, message: string) {
const tag = bold(`[${this.scope}]`);
const color = levelColors[level];
const prefix = color(`${level.toUpperCase()}:`);
console.log(`${tag} ${prefix} ${message}`);
}
}
const logger = new Logger('MyApp');
logger.log('info', 'Application started');
logger.log('success', 'Connection established');
logger.log('warn', 'Deprecated API used');
logger.log('error', 'Failed to connect');
blackredgreenyellowbluemagentacyanwhitegray / greybgBlackbgRedbgGreenbgYellowbgBluebgMagentabgCyanbgWhiteblackBright, redBright, greenBright, yellowBrightblueBright, magentaBright, cyanBright, whiteBrightbgBlackBright, bgRedBright, bgGreenBright, bgYellowBrightbgBlueBright, bgMagentaBright, bgCyanBright, bgWhiteBrightbolddimitalicunderlineinversehiddenstrikethroughresetimport yanse from 'yanse';
// Disable colors
yanse.enabled = false;
console.log(yanse.red('This will not be colored'));
// Re-enable colors
yanse.enabled = true;
console.log(yanse.red('This will be red'));
import yanse from 'yanse';
const styled = yanse.blue.bold('Hello World');
console.log(yanse.unstyle(styled)); // 'Hello World'
console.log(yanse.stripColor(styled)); // 'Hello World' (alias)
import yanse from 'yanse';
yanse.alias('primary', yanse.blue);
yanse.alias('secondary', yanse.gray);
console.log(yanse.primary('Primary text'));
console.log(yanse.secondary('Secondary text'));
import yanse from 'yanse';
yanse.theme({
danger: yanse.red,
success: yanse.green,
warning: yanse.yellow,
info: yanse.cyan,
primary: yanse.blue,
muted: yanse.dim.gray
});
console.log(yanse.danger('Error occurred!'));
console.log(yanse.success('Operation successful!'));
console.log(yanse.warning('Be careful!'));
import { create } from 'yanse';
const customYanse = create();
customYanse.enabled = false; // This instance has colors disabled
console.log(customYanse.red('Not colored'));
enabled: boolean - Enable/disable color outputvisible: boolean - Make output visible/invisibleansiRegex: RegExp - Regex for matching ANSI codeshasColor(str: string): boolean - Check if string contains ANSI codeshasAnsi(str: string): boolean - Alias for hasColorunstyle(str: string): string - Remove ANSI codes from stringstripColor(str: string): string - Alias for unstylealias(name: string, color: YanseColor): void - Create color aliastheme(colors: Record<string, YanseColor>): void - Create color themecreate(): YanseColors - Create new yanse instanceInspired by chalk and ansi-colors.
git clone https://github.com/constructive-io/dev-utils.git
cd dev-utils
pnpm install
pnpm build
cd packages/<packagename>
pnpm test:watch
🛠 Built by the Constructive team — creators of modular Postgres tooling for secure, composable backends. If you like our work, contribute on GitHub.
AS DESCRIBED IN THE LICENSES, THE SOFTWARE IS PROVIDED "AS IS", AT YOUR OWN RISK, AND WITHOUT WARRANTIES OF ANY KIND.
No developer or entity involved in creating this software will be liable for any claims or damages whatsoever associated with your use, inability to use, or your interaction with other users of the code, including any direct, indirect, incidental, special, exemplary, punitive or consequential damages, or loss of profits, cryptocurrencies, tokens, or anything else of value.
FAQs
Fast and lightweight terminal color styling library with chalk-like API
The npm package yanse receives a total of 2,981 weekly downloads. As such, yanse popularity was classified as popular.
We found that yanse demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Research
/Security News
Malicious Chrome and Firefox extensions target Axiom Trade and Padre users, stealing session tokens and wallet data.

Security News
GPT-6 Astra hits 100% on ExploitBench and finds zero-days autonomously, while independent tests reveal scope violations and monitoring gaps.

Product
Socket can now send alerts and supply chain attack notifications to Microsoft Teams, with filters that route the right updates to each channel.