Your browser/OS might not support Object.hasOwn()
if you haven't updated it in a while. It received wide support only about 2 years ago.
If you came here from a google search and you have the same error but it's unrelated to discord.js: Check your browser and OS.
For example, my job requires us to support all iOS devices that can run iOS 15+ (~4 years old at the time of writing). That's not unreasonable; but trying to run some external libraries crashed the app because Object.hasOwn()
got support in iOS 15.4 (~2 years ago at the time of writing).=