Need private packages and team management tools?Check out npm Teams »

uninspected

3.0.1 • Public • Published

uninspected

Replacement for util.inspect and the console object.

NPM version Build Status Coverage Status Dependency Status

var uninspected = require('uninspected');
 
var str = uninspected.inspect({foo: 'bar'}); // "{ foo: 'bar' }"
 
uninspected.log('foo', {bar: /hey/}); // { bar: /hey/ }
 
// Or use this shorthand:
uninspected('foo', {bar: /hey/}); // { bar: /hey/ }

The library also includes diffing support (powered by Unexpected's diffing engine):

uninspected.diff({foo: 'bar'}, {foo: 'baz'});
{
  foo: 'bar' // should be 'baz'
             // -bar
             // +baz
}

You can also use it instead of the console object:

var console = require('uninspected');
 
console.log('...');
 
console.trace();

In the Chrome console this will produce colored output using this API.

The uninspected npm package includes a bookmarklet for doing the above, ie. replacing the console object with uninspected, see bookmarklet.html at the root of the package. Unfortunately github doesn't permit putting it directly into this README.

Install

npm i uninspected

DownloadsWeekly Downloads

30

Version

3.0.1

License

BSD-3-Clause

Unpacked Size

3.72 MB

Total Files

19

Last publish

Collaborators

  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar