I'm trying to create a website builder similar to sites like Squarespace and Wix have where they allow users to build dynamic websites through a custom "WYSIWYG" like website builder. They allow users to edit text, add HTML elements, and much more without writing code.
I'm having conflicts within the code as the scripts that I need to run in my editor are conflicting with the scripts on the actual page itself. (Highlighted area in picture below is the editor I'm talking about on Squarespace, rest of the page is the rendering of the HTML). Conflicts include jQuery versions, css names, javascript function naming conflicts, etc.. as the user can add their own css/javascript. I need some help on how to go about avoiding this and rendering an accurate "preview" of the page.
Any hints, library suggestions or info on going about building something like this would also be appreciated.