最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - What does the `dir` in `console.dir` stand for? - Stack Overflow

programmeradmin5浏览0评论

I get what it does, and use it all the time. But funnily enough, I've yet to find documentation that says what "DIR" actually means. "Directory" doesn't seem right.

This is not a "What's the difference between console.log() and console.dir()?" question. It's simply, "What do the letters DIR actually stand for?"

I get what it does, and use it all the time. But funnily enough, I've yet to find documentation that says what "DIR" actually means. "Directory" doesn't seem right.

This is not a "What's the difference between console.log() and console.dir()?" question. It's simply, "What do the letters DIR actually stand for?"

Share Improve this question edited Jun 1, 2016 at 13:56 RobertAKARobin asked May 31, 2016 at 21:31 RobertAKARobinRobertAKARobin 4,2844 gold badges29 silver badges47 bronze badges 7
  • Do not use it all the time. It is non-standard. – BoltKey Commented May 31, 2016 at 21:33
  • 1 Don't think "directory" as in "folder", think "directory" as in "a listing". – Mr. Llama Commented May 31, 2016 at 21:34
  • 1 I think it just means "Directory". Directory is a synonym for index, list, listing, register, catalogue, record, archive, inventory etc. Some of those words might have been a better fit for this function though. – HaukurHaf Commented May 31, 2016 at 21:35
  • 4 This Q&A helps a little. Hard to saw what the designer intended, but it seems roughly like a "directory" of attributes of the item being displayed. As others have noted, we in the puter field have gotten used to a narrow definition of "directory" but it really is a more general term. – lurker Commented May 31, 2016 at 21:35
  • @BoltKey Don't worry, only for debugging. – RobertAKARobin Commented May 31, 2016 at 22:55
 |  Show 2 more ments

1 Answer 1

Reset to default 9

It just means "Directory". Directory is a synonym for index, list, listing, register, catalogue, record, archive, inventory etc. Some of those words might have been a better fit for this function though, like "listing".

发布评论

评论列表(0)

  1. 暂无评论