KompKit Core is a small cross-platform utility library for Web (TypeScript), Android (Kotlin), and Flutter (Dart).
Status: 0.4.1-alpha.0.
npm i kompkit-coreAdd to your pubspec.yaml:
dependencies:
kompkit_core: ^0.4.1-alpha.0Then run:
flutter pub getAdd to your app/build.gradle.kts:
dependencies {
implementation("com.kompkit:kompkit-core:0.4.1-alpha.0")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2")
}See packages/core/android/README.md for full setup.
Run from the repository root:
# Build web package
npm run build
# Run web tests
npm run test:web
# Run Android/Kotlin tests
cd packages/core/android && ./gradlew test
# Run Flutter tests
cd packages/core/flutter && flutter test| Utility | Description |
|---|---|
debounce |
Debounce a function call by a delay. |
isEmail |
Validate a string with a basic email regex. |
formatCurrency |
Format numbers into a localized currency string. |
clamp |
Constrain a number within an inclusive [min, max] range. |
throttle |
Limit a function to execute at most once per wait period. |
⚠️ Alpha: APIs may change before1.0.0. Pin to an exact version in production.
Next: read the detailed guides for Web, Android, Flutter, and the Recipes.