I want to prevent reloading the page on button click. On click I just want to swap the button values not refresh the page. How can I do so?
<button id="4">134</button> // button 1
<button id="5">234</button> // button 2
After clicking button 1 (button with id of "4") I want the following result
// After clicking button 1
<button id="4">234</button> // button 1
<button id="5">134</button> // button 2
How can I do this without reloading/refreshing the html page.