pub fn state_dir() -> Option<PathBuf>
Returns the path to the user’s state directory.
The state directory contains data that should be retained between sessions (unlike the runtime directory), but may not be important/portable enough to be synchronized across machines (unlike the config/preferences/data directories).
The returned value depends on the operating system and is either a
Some, containing a value from the following table, or a