yamlify-object-colors

Colors preset for yamlify-object

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
yamlify-object-colors
001.0.37 years ago7 years agoMinified + gzip package size for yamlify-object-colors in KB

Readme

yamlify-object-colors
Colors preset for yamlify-object package

Install

npm install yamlify-object-colors

Usage

const yamlifyObject = require('yamlify-object');
const yamlifyColors = require('yamlify-object-colors');

const obj = {
  object: {
    number: 1,
    error: new Error('message'),
    date: new Date(0),
    symbol: Symbol('SYMBOL'),
    string: 'string value',
    boolean: true,
    null: null,
    undefined: undefined,
  }
}

const formattedString = yamlifyObject(obj, {
  colors: yamlifyColors,
});

console.log(formattedString);

Example

Object example