will there be any negative impact if I use the generator function to make the Object prototype traverable?
the code is as follows
Object.prototype[Symbol.iterator] = function* () {
for(let value in this){
yield this[value]
}
}
in fact, the main question is what negative impact it will have, that is, why it is not recommended to modify it, rather than looking for alternatives