{"id":16458259,"url":"https://github.com/matthysdev/cv-kotlin","last_synced_at":"2025-08-02T22:13:47.281Z","repository":{"id":214402844,"uuid":"713547656","full_name":"MatthysDev/cv-kotlin","owner":"MatthysDev","description":null,"archived":false,"fork":false,"pushed_at":"2023-12-27T23:03:43.000Z","size":4549,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-10T03:12:56.830Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MatthysDev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-11-02T18:37:33.000Z","updated_at":"2023-11-02T18:37:51.000Z","dependencies_parsed_at":"2023-12-28T01:06:13.323Z","dependency_job_id":null,"html_url":"https://github.com/MatthysDev/cv-kotlin","commit_stats":null,"previous_names":["matthysdev/cv-kotlin"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatthysDev%2Fcv-kotlin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatthysDev%2Fcv-kotlin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatthysDev%2Fcv-kotlin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatthysDev%2Fcv-kotlin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MatthysDev","download_url":"https://codeload.github.com/MatthysDev/cv-kotlin/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240977832,"owners_count":19887746,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-11T10:44:44.171Z","updated_at":"2025-02-27T04:25:39.482Z","avatar_url":"https://github.com/MatthysDev.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![official project](http://jb.gg/badges/official.svg)](https://confluence.jetbrains.com/display/ALL/JetBrains+on+GitHub)\n[![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\n# [Compose Multiplatform](https://github.com/JetBrains/compose-multiplatform) application\n\n\u003e **Note**\n\u003e The iOS part of Compose Multiplatform is in Alpha. It may change incompatibly and require manual migration in the\n\u003e future.\n\u003e If you have any issues, please report them on [GitHub](https://github.com/JetBrains/compose-multiplatform/issues).\n\nYou can use this template to start developing your\nown [Compose Multiplatform](https://github.com/JetBrains/compose-multiplatform#readme) application targeting desktop,\nAndroid, and iOS.\nFollow our tutorial below to get your first Compose Multiplatform app up and running.\nThe result will be a [Kotlin Multiplatform](https://kotlinlang.org/docs/multiplatform.html) project that uses the\nCompose Multiplatform UI framework.\n\n\u003cimg src=\"readme_images/banner.png\" height=\"350\"\u003e\n\n## Set up the environment\n\n\u003e **Warning**\n\u003e You need a Mac with macOS to write and run iOS-specific code on simulated or real devices.\n\u003e This is an Apple requirement.\n\nTo work with this template, you need the following:\n\n* A machine running a recent version of macOS\n* [Xcode](https://apps.apple.com/us/app/xcode/id497799835)\n* [Android Studio](https://developer.android.com/studio)\n* The [Kotlin Multiplatform Mobile plugin](https://plugins.jetbrains.com/plugin/14936-kotlin-multiplatform-mobile)\n* The [CocoaPods dependency manager](https://kotlinlang.org/docs/native-cocoapods.html)\n\n### Check your environment\n\nBefore you start, use the [KDoctor](https://github.com/Kotlin/kdoctor) tool to ensure that your development environment\nis configured correctly:\n\n1. Install KDoctor with [Homebrew](https://brew.sh/):\n\n    ```text\n    brew install kdoctor\n    ```\n\n2. Run KDoctor in your terminal:\n\n    ```text\n    kdoctor\n    ```\n\n   If everything is set up correctly, you'll see valid output:\n\n   ```text\n   Environment diagnose (to see all details, use -v option):\n   [✓] Operation System\n   [✓] Java\n   [✓] Android Studio\n   [✓] Xcode\n   [✓] Cocoapods\n   \n   Conclusion:\n     ✓ Your system is ready for Kotlin Multiplatform Mobile development!\n   ```\n\nOtherwise, KDoctor will highlight which parts of your setup still need to be configured and will suggest a way to fix\nthem.\n\n## Examine the project structure\n\nOpen the project in Android Studio and switch the view from **Android** to **Project** to see all the files and targets\nbelonging to the project:\n\n\u003cimg src=\"readme_images/open_project_view.png\" height=\"300px\"\u003e\n\nYour Compose Multiplatform project includes 4 modules:\n\n### `shared`\n\nThis is a Kotlin module that contains the logic common for desktop, Android, and iOS applications, that is, the code you\nshare between platforms.\n\nThis `shared` module is also where you'll write your Compose Multiplatform code.\nIn `shared/src/commonMain/kotlin/App.kt`, you can find the shared root `@Composable` function for your app.\n\nIt uses Gradle as the build system. You can add dependencies and change settings in `shared/build.gradle.kts`.\nThe `shared` module builds into a Java library, an Android library, and an iOS framework.\n\n### `desktopApp`\n\nThis is a Kotlin module that builds into a desktop application. It uses Gradle as the build system. The `desktopApp`\nmodule depends on and uses the `shared` module as a regular library.\n\n### `androidApp`\n\nThis is a Kotlin module that builds into an Android application. It uses Gradle as the build system.\nThe `androidApp` module depends on and uses the `shared` module as a regular Android library.\n\n### `iosApp`\n\nThis is an Xcode project that builds into an iOS application.\nIt depends on and uses the `shared` module as a CocoaPods dependency.\n\n## Run your application\n\n### On desktop\n\nTo run your desktop application in Android Studio, select `desktopApp` in the list of run configurations and click **Run**:\n\n\u003cimg src=\"readme_images/run_on_desktop.png\" height=\"60px\"\u003e\u003cbr /\u003e\n\n\u003cimg src=\"readme_images/desktop_app_running.png\" height=\"300px\"\u003e\n\nYou can also run Gradle tasks in the terminal:\n\n* `./gradlew run` to run application\n* `./gradlew package` to store native distribution into `build/compose/binaries`\n\n### On Android\n\nTo run your application on an Android emulator:\n\n1. Ensure you have an Android virtual device available.\n   Otherwise, [create one](https://developer.android.com/studio/run/managing-avds#createavd).\n2. In the list of run configurations, select `androidApp`.\n3. Choose your virtual device and click **Run**:\n\n    \u003cimg src=\"readme_images/run_on_android.png\" height=\"60px\"\u003e\u003cbr /\u003e      \n\n    \u003cimg src=\"readme_images/android_app_running.png\" height=\"300px\"\u003e\n\n\u003cdetails\u003e\n  \u003csummary\u003eAlternatively, use Gradle\u003c/summary\u003e\n\nTo install an Android application on a real Android device or an emulator, run `./gradlew installDebug` in the terminal.\n\n\u003c/details\u003e\n\n### On iOS\n\n#### Running on a simulator\n\nTo run your application on an iOS simulator in Android Studio, modify the `iosApp` run configuration:\n\n1. In the list of run configurations, select **Edit Configurations**:\n\n   \u003cimg src=\"readme_images/edit_run_config.png\" height=\"200px\"\u003e\n\n2. Navigate to **iOS Application** | **iosApp**.\n3. In the **Execution target** list, select your target device. Click **OK**:\n\n   \u003cimg src=\"readme_images/target_device.png\" height=\"400px\"\u003e\n\n4. The `iosApp` run configuration is now available. Click **Run** next to your virtual device:\n\n   \u003cimg src=\"readme_images/ios_app_running.png\" height=\"300px\"\u003e\n\n#### Running on a real iOS device\n\nYou can run your Compose Multiplatform application on a real iOS device for free.\nTo do so, you'll need the following:\n\n* The `TEAM_ID` associated with your [Apple ID](https://support.apple.com/en-us/HT204316)\n* The iOS device registered in Xcode\n\n\u003e **Note**\n\u003e Before you continue, we suggest creating a simple \"Hello, world!\" project in Xcode to ensure you can successfully run\n\u003e apps on your device.\n\u003e You can follow the instructions below or watch\n\u003e this [Stanford CS193P lecture recording](https://youtu.be/bqu6BquVi2M?start=716\u0026end=1399).\n\n\u003cdetails\u003e\n\u003csummary\u003eHow to create and run a simple project in Xcode\u003c/summary\u003e\n\n1. On the Xcode welcome screen, select **Create a new project in Xcode**.\n2. On the **iOS** tab, choose the **App** template. Click **Next**.\n3. Specify the product name and keep other settings default. Click **Next**.\n4. Select where to store the project on your computer and click **Create**. You'll see an app that displays \"Hello,\n   world!\" on the device screen.\n5. At the top of your Xcode screen, click on the device name near the **Run** button.\n6. Plug your device into the computer. You'll see this device in the list of run options.\n7. Choose your device and click **Run**.\n\n\u003c/details\u003e\n\n##### Finding your Team ID\n\nIn the terminal, run `kdoctor --team-ids` to find your Team ID.\nKDoctor will list all Team IDs currently configured on your system, for example:\n\n```text\n3ABC246XYZ (Max Sample)\nZABCW6SXYZ (SampleTech Inc.)\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eAlternative way to find your Team ID\u003c/summary\u003e\n\nIf KDoctor doesn't work for you, try this alternative method:\n\n1. In Android Studio, run the `iosApp` configuration with the selected real device. The build should fail.\n2. Go to Xcode and select **Open a project or file**.\n3. Navigate to the `iosApp/iosApp.xcworkspace` file of your project.\n4. In the left-hand menu, select `iosApp`.\n5. Navigate to **Signing \u0026 Capabilities**.\n6. In the **Team** list, select your team.\n\nIf you haven't set up your team yet, use the **Add account** option and follow the steps.\n\n\u003c/details\u003e\n\nTo run the application, set the `TEAM_ID`:\n\n1. In the template, navigate to the `iosApp/Configuration/Config.xcconfig` file.\n2. Set your `TEAM_ID`.\n3. Re-open the project in Android Studio. It should show the registered iOS device in the `iosApp` run configuration.\n\n## Make your first changes\n\nYou can now make some changes in the code and check that they are visible in both the iOS and Android applications at\nthe same time:\n\n1. In Android Studio, navigate to the `shared/src/commonMain/kotlin/App.kt` file.\n   This is the common entry point for your Compose Multiplatform app.\n\n   Here, you see the code responsible for rendering the \"Hello, World!\" button and the animated Compose Multiplatform logo:\n   \n   ```kotlin\n   @OptIn(ExperimentalResourceApi::class)\n   @Composable\n   internal fun App() {\n       MaterialTheme {\n           var greetingText by remember { mutableStateOf(\"Hello, World!\") }\n           var showImage by remember { mutableStateOf(false) }\n           Column(Modifier.fillMaxWidth(), horizontalAlignment = Alignment.CenterHorizontally) {\n               Button(onClick = {\n                   greetingText = \"Hello, ${getPlatformName()}\"\n                   showImage = !showImage\n               }) {\n                   Text(greetingText)\n               }\n               AnimatedVisibility(showImage) {\n                   Image(\n                       painterResource(\"compose-multiplatform.xml\"),\n                       null\n                   )\n               }\n           }\n       }\n   }\n   ```\n\n2. Update the shared code by adding a text field that will update the name displayed on the button:\n\n   ```diff\n   @OptIn(ExperimentalResourceApi::class)\n   @Composable\n   internal fun App() {\n       MaterialTheme {\n           var greetingText by remember { mutableStateOf(\"Hello, World!\") }\n           var showImage by remember { mutableStateOf(false) }\n           Column(Modifier.fillMaxWidth(), horizontalAlignment = Alignment.CenterHorizontally) {\n               Button(onClick = {\n                   greetingText = \"Hello, ${getPlatformName()}\"\n                   showImage = !showImage\n               }) {\n                   Text(greetingText)\n               }\n   +           TextField(greetingText, onValueChange = { greetingText = it })\n               AnimatedVisibility(showImage) {\n                   Image(\n                       painterResource(\"compose-multiplatform.xml\"),\n                       null\n                   )\n               }\n           }\n       }\n   }\n   ```\n\n3. Re-run the `desktopApp`, `androidApp`, and `iosApp` configurations. You'll see this change reflected in all three\n   apps:\n\n   \u003cimg src=\"readme_images/text_field_added.png\" height=\"350px\"\u003e\n\n## How to configure the iOS application\n\nTo get a better understanding of this template's setup and learn how to configure the basic properties of your iOS app without Xcode,\nopen the `iosApp/Configuration/Config.xcconfig` file in Android Studio. The configuration file contains:\n\n* `APP_NAME`, a target executable and an application bundle name.\n* `BUNDLE_ID`,\n  which [uniquely identifies the app throughout the system](https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleidentifier#discussion).\n* `TEAM_ID`, [a unique identifier generated by Apple that's assigned to your team](https://developer.apple.com/help/account/manage-your-team/locate-your-team-id/#:~:text=A%20Team%20ID%20is%20a,developer%20in%20App%20Store%20Connect).\n\nTo configure the `APP_NAME` option, open `Config.xcconfig` in any text editor *before opening* the project in Android\nStudio, and then set the desired name.\n\nIf you need to change this option after you open the project in Android Studio, do the following:\n\n1. Close the project in Android Studio.\n2. Run `./cleanup.sh` in your terminal.\n3. Change the setting.\n4. Open the project in Android Studio again.\n\nTo configure advanced settings, use Xcode. After opening the project in Android Studio,\nopen the `iosApp/iosApp.xcworkspace` file in Xcode and make changes there.\n\n## Next steps\n\nWe encourage you to explore Compose Multiplatform further and try out more projects:\n\n* [Create an application targeting iOS and Android with Compose Multiplatform](https://github.com/JetBrains/compose-multiplatform-ios-android-template#readme)\n* [Create an application targeting Windows, macOS, and Linux with Compose Multiplatform for Desktop](https://github.com/JetBrains/compose-multiplatform-desktop-template#readme)\n* [Complete more Compose Multiplatform tutorials](https://github.com/JetBrains/compose-multiplatform/blob/master/tutorials/README.md)\n* [Explore some more advanced Compose Multiplatform example projects](https://github.com/JetBrains/compose-multiplatform/blob/master/examples/README.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatthysdev%2Fcv-kotlin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatthysdev%2Fcv-kotlin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatthysdev%2Fcv-kotlin/lists"}