Is there a method which would allow files to be moved to the trash / recycle bin rather than permanently deleted? It would be ideal to give the user the option to restore files if they change their mind or made a mistake.
ie, instead of targetFile.delete(), something like targetFile.moveToTrash()
I’d be fine if become the default behavior for the delete method. Not sure if others are generating massive amounts of files which should be force deleted to avoid bloat in the recycle bin.
Thanks @Maher. This would be a very valuable feature to add to UXP’s file system support.
I appreciate those options, but I’m not sure they are feasible. C++ or an external executable add a lot of complexity, and a custom bin could consume significant space that the user may not be aware of.