In the custom JS code, it’s possible to write a check for if the code is being executed in the Editing window, e.g. Builder.isEditing
.
Is there some equivalent for knowing that the page is being viewed in the Preview feature? I would like to modify the code based on that, so that I can make a change to the page specifically when teammates are previewing a page.