Benjamin Gruenbaum
d8290286b3
doc: document deprecation of util._extend
...
Document that util._extend was never intended to be used
and should be considered deprecated.
PR-URL: https://github.com/nodejs/node/pull/4903
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-03-16 12:55:55 -07:00
Rich Trott
6e6ce09861
doc: copyedit util doc
...
Add verbs to make sentence fragments less fragmentary.
PR-URL: https://github.com/nodejs/node/pull/5399
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-02-25 13:27:47 -08:00
cjihrig
54cbf2826b
doc: note util.isError() @@toStringTag limitations
...
util.isError() is the only remaining util.is*() method that
depends on Object.prototype.toString() behavior. This commit
notes the limitations of isError() related to @@toStringTag.
Refs: https://github.com/nodejs/node/pull/2201
PR-URL: https://github.com/nodejs/node/pull/5414
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
2016-02-25 08:37:37 -05:00
Benjamin Gruenbaum
334a7e3614
doc: replace function expressions with arrows
...
This commit replaces multiple usages of `function(){}` with ES2015
arrow functions in places it was forgotten earlier. The goal is to
make the docs more consistent since other functions were already
replaced with ES2015 arrows.
In addition, it fixes invalid syntax in modules.markdown to valid
syntax as well as remove `var self = this` pattern usages in the code
where they are now possible to avoid through arrow functions.
PR-URL: https://github.com/nodejs/node/pull/4832
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2016-01-27 23:00:20 +01:00
Sakthipriyan Vairamani
4714abb482
doc: show links consistently in deprecations
...
PR-URL: https://github.com/nodejs/node/pull/4907
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: James M Snell <jasnell@gmail.com >
2016-01-27 13:42:45 -08:00
Robert Jefe Lindstaedt
e436272897
doc: fenced all code blocks, typo fixes
...
This changes the code blocks from 4-space indentation to ``` fences for
better syntax highlighting and future linting support. Minor On-the-fly
changes for typos and highlight breaking markdown have been made.
JSON-Style objects have been changed so their closing bracket is
on the same line as the opening one.
Known issues:
* Not every JSON / object notation has been improved. Should
make another run for this.
* Some example functions break hightlighting due to various
combinations of brackets. However changing them means leaving
the code style.
Fixes: https://github.com/nodejs/node/issues/4726
PR-URL: https://github.com/nodejs/node/pull/4733
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-01-21 20:55:09 +01:00
Richard Sun
a2e77cedef
doc: remove "above" and "below" references
...
The docs were recently refactored, and some "above" and "below"
references were no longer accurate. This commit removes many
such references, and replaces others with links.
PR-URL: https://github.com/nodejs/node/pull/4499
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2016-01-11 13:06:00 -05:00
James M Snell
9b21119e17
doc: fix, modernize examples in docs
...
* Use single quotes consistently
* Modernize examples to use template strings and arrow funcs
* Fix a few typos
* Example edits for consistency
PR-URL: https://github.com/nodejs/node/pull/4282
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2015-12-17 08:07:29 -08:00
Roman Klauke
dfc8bedbc5
doc: change references from node to Node.js
...
Some API doc referenced Node.js with "node" or "node.js". This commit
replaces these references.
PR-URL:https://github.com/nodejs/node/pull/4177
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com >
2015-12-10 00:09:38 +09:00
jpersson
14b3aab7d2
doc: add links and backticks around names
...
* add backticks around names
* add single quotes around event names
* add parenthesis after function names
* add internal links between different sections
* add external links to MDN for some JavaScript references
* sort the link definitions alphabetically
PR-URL: https://github.com/nodejs/node/pull/4054
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2015-12-03 13:39:09 -08:00
Wyatt Preul
007cfea308
util: remove pump
...
Remove util.pump and associated tests
PR-URL: https://github.com/nodejs/node/pull/2531
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2015-11-18 14:28:35 -08:00
Bryan English
cd1123a0fb
doc: consistent reference-style links
...
Moved all the URLs in API docs to the bottom of the files as
reference-style links.
PR-URL: https://github.com/nodejs/node/pull/3845
Reviewed-By: James M Snell <jasnell@gmail.com >
2015-11-16 07:36:59 -08:00
Tristian Flanagan
8c703cd040
doc: sort util alphabetically
...
Reorders, with no contextual changes, the util documentation
alphabetically.
PR-URL: https://github.com/nodejs/node/pull/3662
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2015-11-12 17:40:47 -08:00
Evan Lucas
7cb3a5427d
doc: add note to util.isBuffer
...
Since util.isBuffer is deprecated, we should be explicit that
Buffer.isBuffer should be used instead.
PR-URL: https://github.com/nodejs/node/pull/3790
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2015-11-12 12:47:15 -06:00
Sakthipriyan Vairamani
7953c83b85
doc: remove usage of events.EventEmitter
...
The `events` module already exports `EventEmitter` constructor function
So, we don't have to use `events.EventEmitter` to access it.
Refer: https://github.com/nodejs/node/pull/2896
PR-URL: https://github.com/nodejs/node/pull/2921
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Michaël Zasso <mic.besace@gmail.com >
2015-09-23 00:22:11 +05:30
Sakthipriyan Vairamani
93e2830686
doc: document deprecation of util.is* functions
...
This patch documentes the deprecation of util.is* functions.
As per the deprecation policy dicussion, nodejs/dev-policy/issues/49,
we need to start with documenting the deprecation. So, this is
the first step towards officially removing them.
PR-URL: https://github.com/nodejs/node/pull/2447
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rod Vagg <rod@vagg.org >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2015-08-24 08:11:21 +05:30
cjihrig
a69ab27ab4
node: rename from io.js to node
...
This commit replaces instances of io.js with Node.js, based on the
recent convergence. There are some remaining instances of io.js,
related to build and the installer.
Fixes: https://github.com/nodejs/node/issues/2361
PR-URL: https://github.com/nodejs/node/pull/2367
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: João Reis <reis@janeasystems.com >
2015-08-23 17:59:43 -04:00
Nick Raienko
e55fdc47a7
doc: fix util.deprecate example
...
PR-URL: https://github.com/iojs/io.js/pull/1535
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Julian Duque <julianduquej@gmail.com >
2015-04-28 10:12:13 -04:00
Jeremiah Senkpiel
245ba1d658
doc: fix util.isObject documentation
...
Proposed functionality fix containing prior discussion:
https://github.com/iojs/io.js/pull/822
Fixes: https://github.com/iojs/io.js/issues/743
PR-URL: https://github.com/iojs/io.js/pull/1295
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com >
2015-03-31 10:51:23 -04:00
Brendan Ashworth
45814216ee
doc: fix format docs discrepancy
...
Only objects and symbols use `util.inspect`, others are simply
concatenated.
Fixes: https://github.com/iojs/io.js/issues/935
PR-URL: https://github.com/iojs/io.js/pull/1255
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2015-03-25 08:47:41 -07:00
Yazhong Liu
f8c893dd39
doc: fix confusion markdown in util.markdown
...
PR-URL: https://github.com/iojs/io.js/pull/1097
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com >
2015-03-08 14:49:06 -07:00
Chris Dickinson
cf0306cd71
doc: update stability index
...
This simplifies the stability index to 4 levels:
0 - deprecated
1 - experimental / feature-flagged
2 - stable
3 - locked
Domains has been downgraded to deprecated, assert has been
downgraded to stable. Timers and Module remain locked. All
other APIs are now stable.
PR-URL: https://github.com/iojs/io.js/pull/943
Fixes: https://github.com/iojs/io.js/issues/930
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Vladimir Kurchatkin <vladimir.kurchatkin@gmail.com >
2015-02-27 14:23:01 -08:00
Ben Noordhuis
789bbb91d3
doc: update node.js references in api docs
...
Fixes: https://github.com/iojs/io.js/issues/740
PR-URL: https://github.com/iojs/io.js/pull/750
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2015-02-07 17:07:15 -05:00
Thomas Jensen
6f36630f55
doc: fix util.isBuffer examples
...
util.isPrimitive was used in place of util.isBuffer.
PR-URL: https://github.com/iojs/io.js/pull/496
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2015-01-18 22:48:37 +01:00
Brian White
95955a1c4d
doc: update util methods
...
PR-URL: https://github.com/iojs/io.js/pull/350
Reviewed-By: Rod Vagg <rod@vagg.org >
2015-01-14 12:31:55 +11:00
Vladimir Kurchatkin
c70d192ab3
util: show symbol properties
...
Properties with symbol names are shown if option `showHidden` of `util.inspect`
or `console.dir` is `true`.
PR-URL: https://github.com/iojs/io.js/pull/247
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Rod Vagg <rod@vagg.org >
2015-01-08 11:20:15 +01:00
Ben Noordhuis
8b04161342
doc: util: document --trace-deprecation
...
Document the --trace-deprecation flag and the `process` properties that
affect util.deprecate().
Fixes: https://github.com/iojs/io.js/issues/190
PR-URL: https://github.com/iojs/io.js/pull/191
Reviewed-By: Jonathan Ong <me@jongleberry.com >
2014-12-30 23:46:47 +01:00
Trevor Norris
51b6b6844e
doc: fix brackets for optional parameters
...
Documentation incorrectly used bracket notation for optional parameters.
This caused inconsistencies in usage because of examples like the
following:
fs.write(fd, data[, position[, encoding]], callback)
This simply fixes all uses of bracket notation in documentation.
Signed-off-by: Trevor Norris <trev.norris@gmail.com >
Reviewed-by: Fedor Indutny <fedor@indutny.com >
2014-09-25 11:26:15 -07:00
Yazhong Liu
a4f2f9ea8a
doc: add spec for util.deprecate()
...
Signed-off-by: Trevor Norris <trev.norris@gmail.com >
2014-05-07 14:56:21 -07:00
Evan Carroll
95dbb6bf64
util: made util.isArray a direct alias for Array.isArray
2014-04-03 22:39:42 +04:00
isaacs
73d328de24
doc: Adjust util stability index to 'API Frozen'
...
Closes #6087
2013-08-27 19:52:10 -07:00
Timothy J Fontaine
546ae2eef9
util: pass opts to custom inspect functions
...
Objects with custom inpsect functions should get the options that were
passed to `util.inspect()`
fixes #5822
fixes #6098
2013-08-22 16:54:17 -07:00
Ben Noordhuis
2cd7adc7f4
util: don't throw on circular %j input to format()
...
Don't throw an exception when the argument to %j is an object that
contains circular references, it's not helpful. Catch the exception
and return the string '[Circular]'.
2013-07-29 21:59:15 +02:00
isaacs
896b2aa707
util: Add debuglog, deprecate console lookalikes
2013-05-21 16:39:50 -07:00
Nathan Rajlich
3288bc9532
doc: fix inpect() -> inspect() typo
2013-03-12 15:59:10 -07:00
Nathan Rajlich
66280de133
util: custom inspect() method may return an Object
...
This is more like how `JSON.stringify()` works.
Closes #2711 .
2013-03-12 13:18:16 -07:00
Nathan Rajlich
4b238b4c2a
Merge remote-tracking branch 'origin/v0.8'
...
Conflicts:
AUTHORS
ChangeLog
deps/uv/test/runner-win.c
doc/api/process.markdown
lib/repl.js
src/node_crypto.cc
src/node_version.h
2012-10-13 16:16:56 -07:00
Nathan Rajlich
4eb5399bb2
util: add a "customInspect" option to util.inspect()
...
For disabling calling the custom `inspect()` function when defined on an object
that is being inspected.
2012-10-10 14:40:36 -07:00
Nathan Rajlich
07774e6b95
util: make inspect() accept an "options" argument
...
Consolidates all the formatting options into an "options" object argument.
This is so that we don't have to be constantly remembering the order of
the arguments and so that we can add more formatting options easily.
Closes #4085 .
2012-10-10 13:31:47 -07:00
Nathan Rajlich
f826b3269d
doc: document the custom "inspect()" function behavior
...
Closes #3361 .
2012-10-05 16:48:13 -07:00
isaacs
0414e14702
doc: util.pump is deprecated. Use Stream.pipe
...
Conflicts:
doc/api/util.markdown
2012-08-06 08:23:11 -07:00
isaacs
4ff56aa15e
doc: util.pump is deprecated. Use Stream.pipe
2012-08-05 14:47:23 -07:00
Ben Noordhuis
3219616f43
util: mark util.pump() as deprecated
2012-08-05 23:40:28 +02:00
Pavel Lang
ff14007573
Enable color customization of util.inspect
...
This is rewrite of #3701 and #3603 before.
This patch introduce `util.inspect.styles`
and `util.inspect.colors` objects, which enables customization
of color sequences.
2012-07-16 18:32:03 -07:00
Kyle Robinson Young
d9bad09ede
doc: util: add args to format and methods error, puts, print
2012-04-24 05:25:09 +02:00
isaacs
2d44dcc8be
doc: Add stability indicators to documentation
2012-03-03 17:03:52 -08:00
isaacs
3c195d04f3
doc refactor: util
2012-02-29 16:04:54 -08:00
koichik
e1c043f43a
docs: fix docs to not suggest variable leaks
...
Fixes #2106 .
2011-12-27 17:43:58 +09:00
Tim Oxley
871194d5fd
docs: document util.inspect's colors param
2011-12-08 15:47:18 +01:00
Nathan Rajlich
3524f41a27
Add docs for the type checking functions in util.js.
2011-10-27 03:38:29 +09:00