# SwiftUi and CloudKit

**URL:** <https://forums.kodeco.com/t/swiftui-and-cloudkit/85707>\
**Category:** iOS\
**Created:** [October 21, 2019, 3:34pm UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707 "2019-10-21T15:34:47Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![triley52501](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/triley52501/32/81494_2.png) [@triley52501](https://forums.kodeco.com/u/triley52501)\
**Post date:** [October 21, 2019, 3:34pm UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707/1 "2019-10-21T15:34:47Z")

</div>

As we all know in the previous version of Xcode we used Table Views to list out our data collected from iCloud. I Have used it many times in my app.  
With the new Xcode 11 and SwiftUI I am at a loss to get CloudKit to use the List controls to show my data.  
Does anyone have a sample or tutorial that can guide me down this new path?  
T Riley  
Ladybug Development

---

<div class="post-metadata">

**Author:** ![shogunkaramazov](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/shogunkaramazov/32/108826_2.png) [@shogunkaramazov](https://forums.kodeco.com/u/shogunkaramazov)\
**Post date:** [November 14, 2019, 7:42pm UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707/2 "2019-11-14T19:42:31Z")

</div>

@triley52501 Do you still have issues with this?

---

<div class="post-metadata">

**Author:** ![triley52501](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/triley52501/32/81494_2.png) [@triley52501](https://forums.kodeco.com/u/triley52501)\
**Post date:** [November 15, 2019, 7:34am UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707/3 "2019-11-15T07:34:45Z")

</div>

Yes although I spotted a video yesterday on how to use cloud kit in SwiftUI I haven’t attacked it yet but it didn’t look that simple either. Why do you have a solution?

---

<div class="post-metadata">

**Author:** ![jayantvarma](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/jayantvarma/32/111768_2.png) [@jayantvarma](https://forums.kodeco.com/u/jayantvarma)\
**Post date:** [November 15, 2019, 9:41am UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707/4 "2019-11-15T09:41:18Z")

</div>

Hi @triley52501,  
I do not have any code for you, but here’s how you can do that.

1. If you get your data from cloudKit then you can use a List item and display your data as a TableView in SwiftUI

2. In SwiftUI the UI elements need to bind to a state or a data source, so you will need to have a datasource in the form of a Binding or Observable that populates the data from CloudKit and displays it using List items on the UI. This would also hinge a bit on combine.

You can look at the books on SwiftUI, Combine from the store for more details on these topics.

cheers,

---

<div class="post-metadata">

**Author:** ![system](https://s3.amazonaws.com/cdn.raywenderlich.com/community/forum-assets/noun-game-ghost-878668.png) [@system](https://forums.kodeco.com/u/system)\
**Post date:** [April 5, 2020, 7:34am UTC](https://forums.kodeco.com/t/swiftui-and-cloudkit/85707/5 "2020-04-05T07:34:51Z")

</div>

This topic was automatically closed after 166 days. New replies are no longer allowed.
