Israel will have to destroy Hamas. In order to do that, they’ll have to destroy Gaza. Destroying Northern part of Gaza including their “capital city” is a good start.
Even if they wipe all of Hamas off of the face of the Earth, another group will express sympathy and replace them. Hezbollah, for instance.
With ideological zealots who are ignorant AF of regional and world history, you can bet it won’t take long.