Thanks
@CLOVIS! Yeah I haven't traditionally watched this channel, so in the future,
#kobweb is the way to go. (I catch questions in
#compose-web as well).
@アウスジョン(アウス) I actually saw you ask this question on our Discord server, which is a great place to get answers, so I think you already learned what you needed.
But for anyone else curious,
Kobweb is a Kotlin/JS web framework built on top of Compose HTML, and it has a few utility methods that help with loading a file from / saving a file to disk that anyone here is welcome to fork (
FileUtils.kt).
More than that, however, we discussed how there isn't really a traditional "resource bundle" for websites like there are for JVM applications. We discussed how a server somewhere usually hosts resources, and then you fetch them via a GET request. Kobweb provides a convenience class for doing this called
HttpFetcher (accessed via a
window.http
extension property) but you can of course use
window.fetch
directly.