It might be a bit niche, but not everyone knows that you can convert an object to a URLSearchParams without a for loop.
const tokenParams = new URLSearchParams();
for (const [param, value] of Object.entries(tokenBody)) {
tokenParams.set(param, value);
}
new URLSearchParams(Object.entries(tokenBody))
new URLSearchParams(tokenBody)
// This piece of code is adding entries to an existing `URLSearchParam`
for (const [param, value] of Object.entries(tokenBody)) {
tokenParams.set(param, value);
}
No response
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too