JSFiddle - React, Tailwind, and code Playground

by slace

HTML

<input type="button" 
       value="Memory Leaking Insert" onclick="LeakMemory()" />

JavaScript

function LeakMemory(){
        var parentDiv = document.createElement("div");
                          parentDiv.onclick=function(){
            foo();
        };

        parentDiv.bigString = 
          new Array(1000).join(new Array(2000).join("XXXXX"));
    }