node-util icon indicating copy to clipboard operation
node-util copied to clipboard

show a deprecation warning on when using `util.inherit`

Open jimmywarting opened this issue 3 years ago • 1 comments

b/c inherit is discouraged could you give the ppl a warning for using it so ppl will update?

Usage of util.inherits() is discouraged. Please use the ES6 class and extends keywords to get language level inheritance support. @nodejs

jimmywarting avatar Aug 01 '22 16:08 jimmywarting

In what node version was this warning added?

(either way, node-based tests should be emitting this warning regardless)

ljharb avatar Aug 02 '22 10:08 ljharb

It's not deprecated, just legacy, and extremely stable, and it works just fine. a runtime warning would be far too invasive (node.js also doesn't have one).

goto-bus-stop avatar Oct 16 '22 20:10 goto-bus-stop