means What to Cook but → What toCOOK
This fall, I took a course in Kotlin-based development that motivated me to build an application using Kotlin Multiplatform. Although the course only covered the Kotlin language itself, I was determined to create a full Kotlin Multiplatform application.
Previously, I had taken a course in Flutter-based development and built an application with it. However, I wanted to learn Kotlin Multiplatform as well, inspired by its goal of being an improved version of Java.
I started thinking about an application that could help me in my daily life. As a student living far from my parents, I have to cook for myself, and it's often challenging to decide what to make. This led to the idea: an application to help me figure out what to cook each day. The name came naturally: Wha(t to)Cook.
I wanted to build a multiplatform application for all mobile devices. Since I use Linux, targeting iOS directly wasn't feasible. However, by creating a highly responsive application with a web target, I could include iPhone users and make it easily accessible to everyone. And that's what I did — making WhaCOOK available for every user.
- Ingredient Management: Add and manage the ingredients you currently have in your kitchen.
- AI Recipe Generation: Generate creative and delicious recipes using Google Gemini AI, tailored to your available ingredients.
- Recipe Details: View detailed instructions, cooking time, and required ingredients.
- Rating & Favourite Recipes: You can rate recipes individually and mark them as favourite.
- Sort and Filter Recipes: You can sort the recipes by rating and filter them by favourite or rating.
- Edit Recipes: You can edit the generated recipes any time if you found a wrong recipe.
- Multiplatform: Seamlessly runs on Android, Desktop (JVM), and Web (Wasm) with a unified shared codebase.
- Local Storage: Saves your ingredients and preferences locally on your device.
whacook.mp4
For building and running the application on your device you will need AndroidStudio or IntelliJ IDEA , JDK, KMP plugin and Kotlin plugin.
Before starting see set up environment guide.
To use the recipe generation feature, you will need a Google Gemini API Key. You can get one from Google AI Studio.
The app will ask for this key at the first time you open the application, and you can modify it any time under the Menu / API Key menu point.
To run the application on an Android device or emulator:
./gradlew installDebugOr run the androidApp configuration directly from IntelliJ or Android Studio.
To run the application on your desktop:
./gradlew :composeApp:runTo run the application in your browser (using WebAssembly):
./gradlew :composeApp:wasmJsBrowserDevelopmentRunThen open the link shown in the terminal (usually http://localhost:8080).
This project is a Kotlin Multiplatform application leveraging modern technologies:
- Kotlin Multiplatform: For sharing logic across Android, Desktop, and Web.
- Compose Multiplatform: For a unified UI framework.
- Voyager: For multiplatform navigation.
- Koin: For dependency injection.
- Ktor: For networking and API calls.
- Room & SQLDelight: For local data persistence. Room is for Android and JVM targets and SQLDelight for web target as Room does not support web targets.
- Google Gemini API: For AI-powered recipe generation.
This project is licensed under the MIT License.
