Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

tddworks/InAppKit

Repository files navigation

InAppKit

Tests codecov Swift 6.2 Platform

The simplest way to add premium features to your Swift app

Transform any SwiftUI view into a premium feature with just one line of code. InAppKit handles StoreKit complexity so you can focus on building great features.

ContentView()
 .withPurchases("com.yourapp.pro")

🎨 Visual Showcase

InAppKit Paywall
πŸš€ Ready-to-use Paywalls
Beautiful, localized paywalls that work out of the box InAppKit Purchase Options
πŸ’³ Smart Purchase Options
Flexible pricing cards with marketing badges and savings indicators

✨ What You Get

  • πŸš€ One-line setup - Add premium features instantly
  • 🎯 Type-safe features - Enum-based feature gating prevents errors
  • πŸ’³ StoreKit integration - Handles purchases, receipts, and validation
  • 🎨 Customizable paywalls - Beautiful UI out of the box, fully customizable
  • 🌍 Localization support - Built-in internationalization with fallback safety
  • πŸ“± iOS 17+ support - Built with latest SwiftUI and StoreKit 2

🚧 Requirements

  • iOS 17.0+
  • Xcode 15.0+
  • Swift 5.9+

πŸ“¦ Installation

Swift Package Manager

dependencies: [
 .package(url: "https://github.com/tddworks/InAppKit.git", from: "1.0.1")
]

πŸš€ Quick Start

1. Add InAppKit to any view

import InAppKit
ContentView()
 .withPurchases("com.yourapp.pro")

2. Gate premium features

Text("Premium Content")
 .requiresPurchase() // Shows paywall if not purchased

3. That's it!

InAppKit automatically:

  • Creates and displays paywalls when needed
  • Handles StoreKit purchases
  • Validates receipts
  • Remembers purchase state

πŸ“š Learn More

Learn core concepts: Products, Features, and Paywalls

Choose the right strategy: Freemium, Premium, or Subscription

Customize UI, add marketing info, and advanced configuration

Multi-language support with 30+ localization keys and fallback safety

πŸ“– API Reference

Complete API documentation and advanced features

🎯 Real-World Example

enum AppFeature: String, AppFeature {
 case removeAds = "remove_ads"
 case cloudSync = "cloud_sync"
 case exportPDF = "export_pdf"
}
ContentView()
 .withPurchases(products: [
 Product("com.yourapp.pro", features: AppFeature.allCases)
 ])
 .withPaywall { context in
 PaywallView(products: context.availableProducts)
 }

πŸ› οΈ Support

🀝 Contributing

We welcome contributions! Please see our Contributing Guide for details.

πŸ“„ License

Apache-2.0 License. See LICENSE for details.


πŸ™ Acknowledgments

  • Built on Apple's StoreKit 2
  • Inspired by SwiftUI's declarative approach
  • Designed for modern iOS development

Ready to add premium features? β†’ Start with the Getting Started Guide

InAppKit - Because in-app purchases shouldn't be complicated. πŸš€

Made with ❀️ by the TDDWorks team

About

SwiftUI-native framework that simplifies StoreKit integration with a fluent, chainable API and feature-first approach

Resources

License

Stars

Watchers

Forks

Sponsor this project

Packages

Contributors

Languages

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /