Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

Cross-Platform Analytics with KMM

Implementation of the article: Cross-Platform Analytics Made Easy with KMM

Project Structure

├── kmm-shared-library/     # KMM shared module
├── native-android-app/     # Android application
└── native-ios-app/         # iOS application

Setup Instructions

1. Build Shared Library

cd kmm-shared-library
./gradlew build
./gradlew :shared:assembleRelease  # Creates .aar

2. Run Android App

cd native-android-app
# Open in Android Studio
# Run ▶️

3. Run iOS App

cd native-ios-app
# Open in Xcode
# Run ▶️

How It Works

The shared library provides:

  • AnalyticAttribute - Centralized attribute keys
  • AnalyticEvent - Sealed class with event types
  • AnalyticFactory - Factory methods for creating events
  • getAnalyticAttributes() - Converts events to HashMap

Both Android and iOS apps consume the shared library and send events through their native implementations.

About

Cross-platform analytics using KMM. Shared event definitions with type-safe tracking for Android (.aar) and iOS (.xcframework) native apps.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages