Alternatively this can be a tuple of file extension strings. Sketch uses the file extension to find the export filter. Load the module of the plugin Call the module's save function. The function save is the main entry point for an export plugin. It is called with four positional parameters document , file , filename and options .
Currently options is always an empty dictinary as there is no way yet to specify such options.
Apart from the save function entry point Sketch requires very little from the plugin. The only other thing it expects is that the plugin traverses the object tree by itself and uses the interface provided by the Protocols to distinguish the different object types. The interesting parts happen in the class. The Save method is where the real work begins. All compund objects have this method.