How to Clone Containers

I’m in the process of designing a website using EditorX. One of the pages on my website features a container containing two input fields and a button with an ID of ‘btnSubmit’. I’m now attempting to create a code that will generate a new container identical to the first one every time the user clicks the ‘btnSubmit’ button. If the user clicks the button three times, then three containers will appear, one after the other. Unfortunately, I’m having trouble figuring out how to write this code. Could you please assist me by providing guidance or code for this task? I greatly appreciate your help and time.

To generate a new container every time the ‘btnSubmit’ button is clicked on EditorX, you’ll need to use JavaScript. Write a function that creates a new container element using the Document Object Model (DOM) and appends it to the page. Add an event listener to the ‘btnSubmit’ button that calls this function each time the button is clicked.
My Estub Login

You want to create a code that will generate a new container every time the user clicks a button on a page designed with EditorX. Can you please provide guidance or code to accomplish this . ?

I understand you want to add a new container directly to the DOM, which is impossible on Wix as you don’t have access to the window . The only way to achieve similar behavior is to use the $w.Repeater element.