I mean yea, but the consequence of Israel using a nuke would probably be much worse than anything Hamas could ever do.
I don't think Israel is intending to commit genocide, but even if they were, they would have to try and do it in a way that didn't make them as much of a paraiah as North Korea.
The US would totally abandon Israel if they nuked Gaza.