File System & Paths per Platform
Read and write files portably across targets.
Files Live in Different Places
Android and iOS store app files in totally different folders. Shared code needs a portable way to find a safe place to write. 📁
Declare a Paths expect
Put a small expect function in commonMain that returns the app's data directory as a plain String path.
expect fun dataDir(): StringAll lessons in this course
- Design a Capability Interface
- expect/actual for Device Info
- File System & Paths per Platform
- Inject Platform Implementations