The complete source code, a demo of server status switching, and a detailed explanation comparing it with innerHTML are available in the following blog post. [JavaScript] Complete replacement of DOM ...