If the user uninstalls your app, your code is removed from the device. How do you want code that is being removed be executed?
I understand the obvious... but I figure maybe there is some pre-trigger that could possible be sent to the app notifying it's about to be uninstalled.... that doesn't seem so far fetched.
Like for example, for Android, I read somewhere that even though it's hacky, theres a method based on the fact that the first thing android does when uninstalling your app is deleting your data file. So you could use a file watcher to detect the deletion. but I have no idea if that'd really actually work.
I figured if there was some known plugin, me asking the question would prompt a reply with a link to it. But I can't find anything.