
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
An interactive representation of an object for the CLI similar to that of console.dir() in webkit.
Reading big object dumps is a waste of time. Progressive disclosure helps.
Do npm install cdir -g
and then require the module in your program like this console.dir = require('cdir')
.
Use console.dir(someobject)
somewhere in your program and then hit tab
, shift+tab
or the arrow keys to cycle through the object's members. You can hit space
, return
or enter
to expand a member.
Search by pressing the /
key. This will display a /
prompt. If you have already searched for something it will be displayed before the /
prompt. For instance if you searched for "foobar" it would appear as (foobar) /
.
You can add comprehensive line numbers by pressing :
while not in search mode. These line numbers include collapsed nodes so expanding one will not change numbers of later items.
Hit ctrl+c
or q
to quit!
There is a CLI version too if you want to use it. npm install cdir -g
.
console.dir = require('../dir');
var stuff = {
"name" : "cdir",
"description" : "An interactive console.dir() for the terminal.",
"tags" : [
"console",
"debug",
"debugging",
"json",
"interacive",
"prompt"
],
"foo": function() {
return "node tests/test.js"
}
};
console.dir(stuff);
The output looks something like this.
FAQs
An interactive console.dir() for the terminal.
The npm package cdir receives a total of 6 weekly downloads. As such, cdir popularity was classified as not popular.
We found that cdir demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.