Object.groupBy on Vercel
Answered
Peterbald posted this in #help-forum
PeterbaldOP
Hello! I've been using Object.groupBy() in my Next.js project successfully. I'm using the latest TypeScript and have added a d.ts file to support it, but I get the following in my stacktrace when I push it up to Vercel:
What do I need to upgrade to support this? I used
Thanks!
TypeError: Object.groupBy is not a functionWhat do I need to upgrade to support this? I used
create-next-app to make this project.Thanks!
6 Replies
@Peterbald Hello! I've been using Object.groupBy() in my Next.js project successfully. I'm using the latest TypeScript and have added a d.ts file to support it, but I get the following in my stacktrace when I push it up to Vercel:
`TypeError: Object.groupBy is not a function`
What do I need to upgrade to support this? I used `create-next-app` to make this project.
Thanks!
Object.groupBy require node version >= 21.0.0Answer
which is not available on vercel yet
PeterbaldOP
@Ray thanks for replying!
How do we know when it is updated? Thanks.
How do we know when it is updated? Thanks.
When Vercel adds support for Node versions, they will announce it
But generally Vercel doesn’t support odd number versions, so you’ll need to wait until Node 22 LTS is available
@joulev But generally Vercel doesn’t support odd number versions, so you’ll need to wait until Node 22 LTS is available
PeterbaldOP
Thanks for the info.