Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Update] Simplify view model pattern when it is not needed #138

Merged
merged 1 commit into from
Mar 24, 2023

Conversation

yo1995
Copy link
Collaborator

@yo1995 yo1995 commented Mar 23, 2023

Description

Close #123 .

In the swift repo there was a discussion on whether to use StateObject and view model pattern , or simply State, for a geo model (map and scene). In the end we concluded for the simpler samples that don't have extra data flow, State is preferred.

This PR changed all the samples which the view model only holds 1 property which is the geo model.

Linked Issue(s)

  • swift/pull/3698
  • native-apis-doc/issues/3636

How To Test

Run all changed samples and see if they behave the same.

cc @sbaskaran

@yo1995 yo1995 requested a review from vquach2404 March 23, 2023 01:11
@yo1995 yo1995 self-assigned this Mar 23, 2023
@yo1995 yo1995 requested a review from mhdostal March 23, 2023 01:28
@yo1995 yo1995 merged commit 99415f7 into v.next Mar 24, 2023
@yo1995 yo1995 deleted the Ting/Update-Map branch March 24, 2023 00:01
@dfeinzimer dfeinzimer mentioned this pull request Mar 24, 2023
@yo1995 yo1995 moved this from In Progress to Done in SwiftUI Sample Viewer prototyping Mar 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants