A student asked how can I add a button when a button is clicked.
There are many more traditional (and arguably better) ways than this, but it would be tough to beat the brevity and speed here.
<button onclick="this.parentElement.innerHTML+=this.outerHTML">Me</button>
Click on the “me” button right here on this page.
or follow this link to a live editable code example.
https://replit.com/@kevinelong/button-clone