A beautiful Android home screen widget inspired by Duolingo's streak feature, designed to help you stay consistent with your LeetCode practice.
- π₯ Fire Icons: Completed days show with fire emojis instead of boring checkmarks
- π Live Streak Tracking: Real-time streak updates from your LeetCode profile
- π 7-Day Rolling View: Shows the last 7 days with today always as the last day
- π Statistics: Total solved problems, longest streak, and difficulty breakdown
- π Auto-Refresh: Updates every 30 minutes automatically
- π― Manual Refresh: Tap the refresh button for instant updates
- π¨ Modern UI: Clean, Duolingo-inspired design that fits perfectly on your home screen
Latest Release: v1.0.0
- Download the APK from the link above
- Enable Unknown Sources:
- Go to Settings β Security β Unknown Sources (Android 7 and below)
- Or Settings β Apps β Special Access β Install Unknown Apps (Android 8+)
- Install the APK by tapping on the downloaded file
- Add Widget to Home Screen:
- Long press on your home screen
- Tap the "+" button
- Search for "LeetCode Streak"
- Select the widget size and tap "Add Widget"
- Configure in App:
- Open the LeetCode Streak app
- Enter your LeetCode username
- Tap "Save"
- Node.js >= 20.19.4
- React Native CLI
- Android Studio
- Java Development Kit (JDK)
# Clone the repository
git clone https://github.com/YOUR_USERNAME/LeetcodeStreakWidget.git
cd LeetcodeStreakWidget
# Install dependencies
npm install
# For Android
cd android
./gradlew clean
cd ..
# Run the app
npm run android# Build release APK
cd android
./gradlew assembleRelease
# APK will be generated at:
# android/app/build/outputs/apk/release/app-release.apk- Frontend: React Native 0.82.0
- Backend: LeetCode GraphQL API
- Widget: Native Android (Kotlin)
- Data Storage: AsyncStorage + SharedPreferences
- State Management: React Hooks
βββ src/
β βββ components/ # React Native components
β βββ services/ # API and storage services
β βββ screens/ # App screens
βββ android/
β βββ app/src/main/
β β βββ java/com/leetcodestreakwidget/
β β β βββ LeetCodeWidgetProvider.kt # Widget logic
β β β βββ WidgetDataService.kt # Data management
β β β βββ WidgetBridgeModule.kt # React Native bridge
β β βββ res/
β β βββ layout/ # Widget layouts
β β βββ drawable/ # Icons and graphics
βββ README.md
- LeetCodeAPI: Fetches user data from LeetCode GraphQL API
- WidgetService: Manages data synchronization with native widget
- StorageService: Handles local data persistence
- LeetCodeWidgetProvider: Main widget provider handling updates
- WidgetDataService: Manages widget data storage
- WidgetBridgeModule: Bridge between React Native and native code
The widget automatically updates every 30 minutes. You can manually refresh by:
- Pulling down in the app
- Tapping the refresh button on the widget
- LeetCode Username: Your public LeetCode profile
- Submission Calendar: Daily coding activity data
- Statistics: Total solved problems by difficulty
- Data Fetching: App fetches your LeetCode data via GraphQL API
- Streak Calculation: Calculates consecutive days with submissions
- Widget Update: Native Android widget displays the data
- Auto-Refresh: Widget updates automatically every 30 minutes
The widget shows a 7-day rolling window:
- Day 1-6: Previous days (6 days ago to yesterday)
- Day 7: Today (always the rightmost day)
- Fire Icons: Days with LeetCode submissions
- Gray Circles: Days without submissions
We welcome contributions! Please feel free to submit a Pull Request.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by Duolingo's streak feature
- LeetCode for providing the API
- React Native community for excellent documentation
- Android widget development community
If you encounter any issues or have questions:
- Check the Issues page
- Create a new issue with detailed description
- Include screenshots if applicable
Give a βοΈ if this project helped you stay consistent with your coding practice!
Happy Coding! π₯ Keep that streak alive! πͺ

