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

RN Changes 4 #740

Closed
wants to merge 5 commits into from
Closed

RN Changes 4 #740

wants to merge 5 commits into from

Conversation

christopherjbaker
Copy link
Contributor

No description provided.

@christopherjbaker christopherjbaker marked this pull request as draft May 15, 2024 03:43
data: State[] | undefined
error: Error | undefined
isPending: boolean
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? They’re in alphabetical order right now and that’s nice for scanning property names.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Except for very long lists, I don't find alphabetical a very useful way to organize things. I usually order things by when are used, how often they're needed, the value they bring, etc. In this case: isPending is metadata about the rest of the items. (If there was a status, I'd put it first since isPending is derived from it.) `It will also be needed more frequently than the other two.

readonly GOOGLE_OAUTH_CLIENT_ID: string
readonly GOOGLE_MAPS_API_KEY: string
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, why this change? Alphabetical order is always nice for quickly scanning.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For trainings, I also sorting things in the order they're introduced to the audience. Besides making it clearer where they will put things or where to look in solutions, it also improves the quality an cleanliness of diffs (in general, but even moreso with the academy diff algorithm). (The diffing doesn't apply to this line, it explains the changes in several files in the last PR.)

@christopherjbaker christopherjbaker deleted the rn-updates-4 branch May 17, 2024 18:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants