-
-
Notifications
You must be signed in to change notification settings - Fork 20.5k
Closed
Labels
Description
It seems that we can remove a few dependencies before the 5.0
release:
methods
- We can use the built-inhttp
module:
const { METHODS } = require("http");
const methods = METHODS.map((method) => method.toLowerCase());
path-is-absolute
- We can use the built-inpath
module:
const path = require("path");
const isAbsolute = path.isAbsolute("some-path");
safe-buffer
- We can use the built-inBuffer
:
const a = Buffer.from("something");
setprototypeof
- We can use theObject.setPrototypeOf()
Object.setPrototypeOf(this.request, parent.request);
utils-merge
- We can use the spread operator:
const opts = { expires: new Date(1), path: '/' , ...options};
LinusU, barisusakli, Mirobit, ex1st, theoludwig and 52 moreMilo123459, RamirezAlex, MarkSFrancis, Asjas, oceandrama and 5 moremariusa, PazzaVlad, gu-stav, anfragment, Milo123459 and 12 moreoceandrama, sandstrom, dwoodwardgb, lucaslago and vuki656jonchurch, Milo123459, RamirezAlex, oceandrama, sandstrom and 3 more