pub fn save_to_cache<T: Serialize>(filename: &str, data: &T) -> Result<()>
Saves serializable data to a file in the cache directory. The data is serialized as JSON.