Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

chalk

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chalk - npm Package Compare versions

Comparing version 0.2.1 to 0.3.0

6

chalk.js

@@ -30,3 +30,5 @@ 'use strict';

get: function () {
var obj = defineProps(function self(str) {
var obj = defineProps(function self() {
var str = [].slice.call(arguments).join(' ');
if (!chalk.enabled) {

@@ -55,3 +57,3 @@ return str;

chalk.stripColor = function (str) {
return str.replace(/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]/g, '');
return typeof str === 'string' ? str.replace(/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]/g, '') : str;
};

@@ -58,0 +60,0 @@

{
"name": "chalk",
"version": "0.2.1",
"version": "0.3.0",
"description": "Terminal string styling done right",

@@ -5,0 +5,0 @@ "keywords": [

@@ -37,3 +37,3 @@ # chalk [![Build Status](https://secure.travis-ci.org/sindresorhus/chalk.png?branch=master)](http://travis-ci.org/sindresorhus/chalk)

// combine styled and normal strings
console.log(chalk.blue('Hello') + 'World' + chalk.red('!'));
console.log(chalk.blue('Hello'), 'World' + chalk.red('!'));

@@ -44,3 +44,6 @@ // compose multiple styles using the chainable API

// nest styles
chalk.red('Hello' + chalk.underline.bgBlue('world') + '!');
chalk.red('Hello', chalk.underline.bgBlue('world') + '!');
// pass in multiple arguments
console.log(chalk.blue('Hello', 'World!', 'Foo', 'bar', 'biz', 'baz'))
```

@@ -63,2 +66,3 @@

Multiple arguments are also supported. Chalk will add a space between each one.

@@ -65,0 +69,0 @@ ### chalk.enabled

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc