https://github.com/danielsaidi/deckkit
DeckKit is a Swift SDK that helps you build deck-based apps in SwiftUI.
https://github.com/danielsaidi/deckkit
ios macos swift swiftui tvos visionos watchos
Last synced: 7 months ago
JSON representation
DeckKit is a Swift SDK that helps you build deck-based apps in SwiftUI.
- Host: GitHub
- URL: https://github.com/danielsaidi/deckkit
- Owner: danielsaidi
- License: mit
- Created: 2020-08-31T05:51:52.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-05-06T08:16:00.000Z (over 1 year ago)
- Last Synced: 2024-05-13T14:09:19.553Z (over 1 year ago)
- Topics: ios, macos, swift, swiftui, tvos, visionos, watchos
- Language: Swift
- Homepage:
- Size: 13.3 MB
- Stars: 566
- Watchers: 8
- Forks: 14
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# DeckKit
DeckKit is a SwiftUI SDK that lets you build deck-based apps with ease. It has a `DeckView` that can render any list of items, with support for swipe gestures, edge swipes, shuffling, etc.
DeckKit can be customized to great extent. You can change colors, fonts, etc. and use completely custom views. It also has tools to manage favorites.
## Installation
DeckKit can be installed with the Swift Package Manager:
```
https://github.com/danielsaidi/DeckKit.git
```
## Getting started
With DeckKit, you can create a deck of cards with any type that conforms to `Identifiable`:
```swift
struct Hobby: Identifiable {
var name: String
var text: String
var id: String { name }
}
struct MyView: View {
@State
var hobbies: [Hobby] = ...
var body: some View {
DeckView($hobbies) { hobby in
RoundedRectangle(cornerRadius: 25.0)
.fill(.blue)
.overlay(Text(hobby.name))
.shadow(radius: 10)
}
}
}
```
DeckKit has several view components for presenting decks, e.g. `DeckView` and `DeckPageView`.
See the online [getting started guide][Getting-Started] for more information.
## Documentation
The online [documentation][Documentation] has more information, articles, code examples, etc.
## Demo Application
The `Demo` folder has an app that lets you explore the library on iOS, macOS, and visionOS.
## Support my work
You can [sponsor me][Sponsors] on GitHub Sponsors or [reach out][Email] for paid support, to help support my [open-source projects][OpenSource].
Your support makes it possible for me to put more work into these projects and make them the best they can be.
## Contact
Feel free to reach out if you have questions or want to contribute in any way:
* Website: [danielsaidi.com][Website]
* E-mail: [daniel.saidi@gmail.com][Email]
* Bluesky: [@danielsaidi@bsky.social][Bluesky]
* Mastodon: [@danielsaidi@mastodon.social][Mastodon]
## License
DeckKit is available under the MIT license. See the [LICENSE][License] file for more info.
[Email]: mailto:daniel.saidi@gmail.com
[Website]: https://www.danielsaidi.com
[GitHub]: https://www.github.com/danielsaidi
[Bluesky]: https://bsky.app/profile/danielsaidi.bsky.social
[Twitter]: https://www.twitter.com/danielsaidi
[Mastodon]: https://mastodon.social/@danielsaidi
[Sponsors]: https://github.com/sponsors/danielsaidi
[OpenSource]: https://www.danielsaidi.com/opensource
[Documentation]: https://danielsaidi.github.io/DeckKit/
[Getting-Started]: https://danielsaidi.github.io/DeckKit/documentation/deckkit/getting-started
[License]: https://github.com/danielsaidi/DeckKit/blob/master/LICENSE