It does work on OpenProcessing too:
However, b/c we can’t control the order the multi-tabs are loaded there, the global variable sketches[] defined within the main tab may not exist yet when the other tabs happen to be run 1st.
As a workaround, we can have this statement on each tab:
var sketches = window.sketches || [];
It makes sure to create an Array and assign it to sketches[] if 1 isn’t already present in it.