KuiklyUI
๐ Kotlin Multiplatform UI framework from Tencent TDS โ High-performance cross-platform framework with unified codebase, ease of use, and dynamic flexibility.
Install / Use
/learn @Tencent-TDS/KuiklyUIREADME
English | ็ฎไฝไธญๆ | Homepage
Introduction
Kuikly is a comprehensive cross-platform solution for UI and logic based on Kotlin multi-platform. It was launched by Tencent's company-level Oteam in the front-end field. It aims to provide a high-performance, full-platform development framework with unified codebase, ultimate ease of use, and dynamic flexibility. Currently supported platforms:
- [X] Android
- [X] iOS
- [X] HarmonyOS
- [X] Web (Beta)
- [X] Mini Programs (Beta)
- [X] macOS (Alpha)
Since its launch, Kuikly has gained wide recognition from the business. It has been used by many products such as QQ, QQ Music, QQ Browser, Tencent News, Sogou Input Method, MyApp Hub(Tencent's app store), WeSing, Kugou Music, Kuwo Music, Tencent Self-selected Stock, ima.copilot, Weishi, etc.
Key Features
- Cross-platform: Kotlin-based implementation ensuring consistent operation across multiple platforms - one codebase, six platforms
- Native performance: Generates platform-native binaries (.aar/.framework/.so)
- Native development experience: Native UI rendering, native toolchain support, Kotlin as primary language
- Lightweight: Minimal SDK footprint (AOT mode: ~300KB for Android, ~1.2MB for iOS)
- Dynamic capability: Supports compilation into dynamic deliverables
- Multiple paradigms: Supports both declarative & reactive programming, with self-developed DSL and Compose DSL
Project Structure
.
โโโ core # Cross-platform module implementing core capabilities like responsive UI, layout algorithms, Bridge communication, etc.
โโโ src
โโโ commonMain # Shared cross-platform code, defining cross-platform interfaces
โโโ androidMain # Android platform implementation (outputs aar)
โโโ jvmMain # Generic JVM platform code (no Android APIs, outputs jar)
โโโ appleMain # apple platform (iOS & macOS) implementation (outputs framework)
โโโ ohosArm64Main # Ohos platform implementation๏ผoutputs so๏ผ
โโโ jsMain # H5 and MiniApp platform implementation๏ผoutputs js๏ผ
โโโ core-render-android # Android platform renderer module
โโโ core-render-ios # iOS platform renderer module
โโโ core-render-ohos # HarmonyOS platform rendering module
โโโ core-render-web # H5 and MiniApp platform rendering module
โโโ core-annotations # Annotations module, defining business annotations like @Page
โโโ core-ksp # Annotation processing module, generates Core entry files
โโโ buildSrc # Build scripts for compilation, packaging, and artifact splitting
โโโ demo # DSL example code
โโโ androidApp # Android host shell project
โโโ iosApp # iOS host shell project
โโโ macApp # macOS host shell project
โโโ ohosApp # Ohos host shell project
โโโ miniApp # miniApp host shell project
โโโ h5App # h5App host shell project
โโโ compose # Cross-platform module implementing Compose UI, layout, and Kuikly bridging capabilities
โโโ src
โโโ commonMain # Shared cross-platform code, including Compose UI components, layout and event handling
โโโ androidMain # Android platform specific implementation
โโโ nativeMain # iOS and HarmonyOS platform specific implementation
โโโ jsMain # H5 and MiniApp platform specific implementation
Note: The Compose directory contains cross-platform source code based on Jetpack Compose 1.7.3 version. We have made necessary modifications and adaptations to the original Compose code to support Kuikly framework's rendering requirements. Some unnecessary features have been commented out to facilitate future upgrades. To ensure stable feature support and avoid conflicts with official code, we have changed the package name from
androidx.composetocom.tencent.kuikly.compose. The original Compose code is from JetBrains Compose Multiplatform.
System Requirements
- iOS 12.0+
- macOS 10.13+
- Android 5.0+
- HarmonyOS Next 5.0.0(12)+
- Kotlin 1.3.10+
Getting Started
Building from Source
Environment Setup
Refer to Environment Configuration
-
if your Android Studio Version >= (2024.2.1) Please switch your Gradle JDK Version to JDK17 (this Version default Gradle JDK is 21, it incompatible with the configuration used by the project)
Android Studio -> Settings -> Build,Execution,Deployment -> Build Tools -> Gradle -> Gradle JDK
-
DevEco Studio 5.1.0 or newer(API Version >= 18)(You can check the API Version throughใ DevECo Studio -> Help -> About HarmonyOS SDK ใ)
-
JDK17
Running Android App
Ensure environment preparation is complete before building:
- Open
KuiklyUIroot directory inAndroid Studioand sync project - Select androidApp configuration, then Run 'androidApp'
Running iOS App
Ensure environment preparation is complete before building:
- Navigate to
iosAppdirectory - Execute
pod install --repo-update - Open
KuiklyUIroot directory in Android Studio and sync project - Select iOSApp configuration, then Run 'iOSApp'
Alternatively, open KuiklyUI/iosApp in Xcode and Run
Note: The iosApp project will execute the KMP script when compiling. If you encounter an error with the script read and write file permissions, you need to set
User Script SandboxingtoNoinXcode -> Build Setting.
Running Ohos APP
Ensure environment preparation is complete before building:
Mac
- In
KuiklyUIroot directory, run the HarmonyOS cross-platform product compile script:./2.0_ohos_demo_build.sh - Open
KuiklyUI/ohosAppin DevEco Studio and sync project - Connect to Ohos Phone or start the Ohos Emulator, and perform a signature operation
File -> Project Structure -> Signing Configs - Use DevEco Studio Run
entry, Run OhosApp
Windows
-
Configure environment variables pointing to HarmonyOS SDK path:
Variable: OHOS_SDK_HOME Path: %TOOL_HOME%\sdk Variable: TOOL_HOME Path: D:\DevEcoStudioNote: "D:\DevEcoStudio" uses D drive as an example. Any drive except C drive can be used.
-
In
KuiklyUIroot directory, run the Windows build script:2.0_ohos_demo_build.batOr run manually:
set KUIKLY_AGP_VERSION=7.4.2 set KUIKLY_KOTLIN_VERSION=2.0.21-KBA-010 gradlew.bat -c settings.2.0.ohos.gradle.kts :demo:linkSharedDebugSharedOhosArm64 -
Copy artifacts to ohosApp (automatically done by bat script):
demo\build\bin\ohosArm64\sharedDebugShared\libshared.soโohosApp\entry\libs\arm64-v8a\demo\build\bin\ohosArm64\sharedDebugShared\libshared_api.hโohosApp\entry\src\main\cpp\thirdparty\biz_entry\
-
Open
KuiklyUI/ohosAppin DevEco Studio and sync project -
Connect to Ohos Phone or start the Ohos Emulator, and perform a signature operation
File -> Project Structure -> Signing Configs -
Use DevEco Studio Run
entry, Run OhosApp
Note: Windows compilation requires Kotlin toolchain version
2.0.21-KBA-010which supports Windows/Linux platforms.
Kotlin Version Support
The KuiklyUI directory contains Gradle configurations for various Kotlin versions:
Naming convention: x.x.xx.gradle.kts (default uses Kotlin 2.0.21)
Test publishing scripts for each version are available as x.x.xx_test_publish.sh for building local artifacts.
Note: Kotlin 1.3.10/1.4.20 require JDK11
After successful build on any platform, you can modify Core, Render, and Demo to experience Kuikly development.
Quick Demo Experience
<div style="display: inline-block; text-align: left;"> <img src="img/kuikly_demo_android_qr.png" width="200"> </div>Scan the QR code with an Android phone to quickly try the demo. For iPhone and HarmonyOS phones, please follow the steps above to compile and experience the demo app from the source code.
Roadmap
Contribution Guidelines
We welcome all developers to submit issues or PRs for Kuikly. Please review our Contribution Guide before contributing.
Code of Conduct
All project participants are expected to adhere to our Code of Conduct. Participation constitutes agreement to these terms.
FAQs
Contributors
- Special thanks to the first batch of contributors tom(้ฑ่ฏ้), kam(ๆ้ฆๆถ), and watson(้็), who not only pioneered the incubation and exploration of the
Kuiklycross-platform solutions in the frontend field, but also were the first to implement them in the QQ business. - Thanks to the following core contributors for the continuous construction, maintenance, development and optimization of
Kuikly: <br>tom kam watson rocky jonas ruifan pel layen bird zealot zhenhua vinney xuanxi ray arnon alexa allens eason - We also extend our sincere gratitude to every community contributor who has participated in the development of
Kuikly. It is your collective effort that drives the continuous growth and improvement ofKuikly. <div id="list" style="display: flex; flex-wrap: wrap"><a href="https://github.com/Tencent-TDS/KuiklyUI
Related Skills
node-connect
333.7kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
82.0kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
333.7kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
82.0kCommit, push, and open a PR
