Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cxwudi/realworld-compose-http4k-example-app
An unfinished Conduit (https://github.com/gothinkster/realworld) example app developed in Compose Multiplatform and Http4k
https://github.com/cxwudi/realworld-compose-http4k-example-app
compose-multiplatform decompose exposed http4k koin kotlin-multiplatform kstore mvikotlin
Last synced: about 2 months ago
JSON representation
An unfinished Conduit (https://github.com/gothinkster/realworld) example app developed in Compose Multiplatform and Http4k
- Host: GitHub
- URL: https://github.com/cxwudi/realworld-compose-http4k-example-app
- Owner: CXwudi
- License: mit
- Created: 2024-07-09T19:44:20.000Z (7 months ago)
- Default Branch: master
- Last Pushed: 2024-12-08T18:09:20.000Z (about 2 months ago)
- Last Synced: 2024-12-08T18:28:35.309Z (about 2 months ago)
- Topics: compose-multiplatform, decompose, exposed, http4k, koin, kotlin-multiplatform, kstore, mvikotlin
- Language: Kotlin
- Homepage:
- Size: 1.54 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# ![RealWorld Example App](logo.png)
2024.10 Update: I am going to implement a minimal set of features in frontend first, more info in this discussion
>
Compose Multiplatform + http4k codebase containing real world examples (CRUD, auth, advanced patterns, etc) that adheres to the RealWorld spec and API.
| Phone | Desktop | Web|
|---|---|---|
| ![Phone App Screenshot](screenshots/Screenshot_20240911_105149.png) | ![Desktop App Screenshot](screenshots/2024-09-11%2010-52-34.png) Click to enlarge | ![Web App Screenshot](screenshots/2024-09-11%2010-55-35.png) Click to enlarge |This codebase was created to demonstrate a fully fledged fullstack application built with **[Compose Multiplatform](https://www.jetbrains.com/lp/compose-multiplatform/)** and **[http4k](https://www.http4k.org/)** including CRUD operations, authentication, routing, pagination, and more.
We've gone to great lengths to adhere to the community styleguides & best practices of **Compose Multiplatform** and **http4k**.
For more information on how this works with other frontends/backends, head over to the [RealWorld](https://github.com/gothinkster/realworld) repo.
## How it works
The project is divided into 4 modules:
1. [`conduit-common`](./conduit-common) - the shared code between the client and the server.
2. [`conduit-frontend`](./conduit-frontend) - the KMP client source code.
3. [`conduit-backend`](./conduit-backend) - the server source code.
4. [`build-src`](./build-src) - shared Gradle build logic, including the [version catalog](./build-src/libs.versions.toml) that is used globally across the project.## Develop
Install Android Studio and IntelliJ IDEA, then:
- Frontend: Open the `conduit-frontend` directory in Android Studio.
- Backend: Open the `conduit-backend` directory in IntelliJ IDEA.### About Frontend
For frontend development, you need to follow this [guide](https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-setup.html#check-your-environment) to set up the Compose Multiplatform development environment.
`conduit-frontend` declares all 4 platforms of JVM, Android, JS, and iOS. However, iOS is only declared in Gradle but not developed since I don't have a Mac machine.
`conduit-frontend` contains multiplatform tests that run on all 4 platforms. However, tests on the JS platform require a browser, so far `useChromiumHeadless()` is defined in [`kmp-library.gradle.kts`](build-src/plugins/multiplatform-library/src/main/kotlin/my/kmp-library.gradle.kts), which means you need to install Chromium for running tests on the JS platform. If you already have a Chrome browser, feel free to change to `useChromeHeadless()`(or `useFirefox()` and others) for your convenience.