-
Notifications
You must be signed in to change notification settings - Fork 13
Description
It seems you didn't take into account that Processing supports sketches made of more than one .pde file, e.g. with one main sketch file plus one file per class definition. You can add files from the IDE.
In Java mode they are compiled together.
processing.js also supports that by simply inserting the list of files in the data-processing-sources attribute of the canvas node.
However, JavaScript mode ignores that, only copies the one main .pde file into the web-export folder, and only includes that one in the data-processing-sources attribute.
This renders JavaScript mode useless for sketches including more than one file.
Additionally, since the web-export folder is wiped out every time the sketch is exported, there doesn't even seem to be an easy workaround.
JavaScript mode should copy all .pde files, not only the one with the same name as the folder, into web-export, and include all of them in the data-processing-sources attribute (I don't remember if they need to be separated by commas or spaces or what)