Skip to content

Commit

Permalink
Fix Favorites case study by using episode mocks (#2962)
Browse files Browse the repository at this point in the history
* Fix favorites case study by using episode mocks

* Small tweaks

---------

Co-authored-by: Brandon Williams <[email protected]>
  • Loading branch information
beribas and mbrandonw authored Apr 1, 2024
1 parent 2722a34 commit 0301506
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion Examples/CaseStudies/SwiftUICaseStudies/00-RootView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,11 @@ struct RootView: View {

Section {
NavigationLink("Reusable favoriting component") {
Demo(store: Store(initialState: Episodes.State()) { Episodes() }) { store in
Demo(store: Store(
initialState: Episodes.State(episodes: .mocks)
) {
Episodes()
}) { store in
EpisodesView(store: store)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ extension IdentifiedArray where ID == Episode.State.ID, Element == Episode.State
#Preview {
NavigationStack {
EpisodesView(
store: Store(initialState: Episodes.State()) {
store: Store(initialState: Episodes.State(episodes: .mocks)) {
Episodes()
}
)
Expand Down

0 comments on commit 0301506

Please sign in to comment.