Hello everyone. Dummy question here, I never used ...
# io
f
Hello everyone. Dummy question here, I never used kotlinx-io before. I want write simple text to a file, and append more text later. Can use a sink for that??
I am trying to use in a common module.
Copy code
private val path = Path("Documents", "test.txt")

SystemFileSystem.sink(path = path, append = true).buffered().use { sink ->
    sink.writeString(message)
}
What is the correct way to write to Android/IOS filesystem??
m
Exactly the same provided you have a valid path with write access.