I need JS help. I want to set the innerHTML of a div to a certain string. But in the process, some elements are removed without any explanation. A minimal example:
This is the code.
This is the confusing result. When written to the console, the string is what I want, but when written to the HTML, it's altered.