I see a lot of scripts that define their UI in a string and then add it to the panel, like this:
var myPanel = (thisObj instanceof Panel) ? thisObj : new Window("palette", "My Panel Name", [0, 0, 300, 300]);
res="group{orientation:'column', alignment:['fill', 'fill'], alignChildren:['fill', 'fill'],\
// Then a whole bunch of groups of tabs
}"
//Add resource string to panel
myPanel.grp = myPanel.add(res);
What benefit does this give you compared to defining each group / tab / etc as a variable and using standard scripting?