how to clear user data while delete mac electron app from application directly?
问题 how to delete user data while deleting the macos electron app? It seems we need to write a daemon to listen to the folders change, but how to do? do you have more clear or easier methods to handle it? packaging used electron-builder. 回答1: I use electron-localstorage to set one flag into app, while everytime you start app, which will check if the flag can get from app, if not, this was new installed and opend first time, so it will clear the old userdata. const userDataPath = app.getPath(