Skip to content

feat(react navigation): use static screens configuration #513

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

Merged
merged 4 commits into from
Jun 29, 2025

Conversation

dannyhw
Copy link
Collaborator

@dannyhw dannyhw commented May 30, 2025

Description

moves templates to the static configuration

note that I moved to the stylesheet api for unistyles because the config is static so its more complicated to use a hook in the setup of the screen options

Related Issue

Motivation and Context

its the suggested way by the react navigation team

How Has This Been Tested?

tested with these combinations

['--react-navigation', '--tabs', '--stylesheet'],
  ['--react-navigation', '--tabs+drawer', '--stylesheet'],
  ['--react-navigation', '--stack', '--stylesheet'],
  ['--react-navigation', '--tabs', '--unistyles'],
  ['--react-navigation', '--tabs+drawer', '--unistyles'],
  ['--react-navigation', '--stack', '--unistyles'],

Screenshots (if appropriate):

image

@dannyhw dannyhw force-pushed the dannyhw/feat-static-react-navigation branch from 989739e to 8a04f0d Compare May 30, 2025 19:37
@dannyhw dannyhw marked this pull request as ready for review May 30, 2025 20:04
@dannyhw dannyhw requested a review from danstepanov May 30, 2025 20:05
@dannyhw dannyhw changed the title feat: static react navigation config feat(react navigation): use static screens configuration May 30, 2025
@danstepanov
Copy link
Collaborator

@jpudysz thoughts on this?

Copy link
Contributor

@jpudysz jpudysz left a comment

Choose a reason for hiding this comment

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

I think there is no need to refactor it that way.

fix

fix

fix

fix: unistyles warning

feat: use rnn theme together with unistyles theme

remove file
@dannyhw dannyhw force-pushed the dannyhw/feat-static-react-navigation branch from d205331 to 4ae6f71 Compare June 14, 2025 14:57
@dannyhw dannyhw requested a review from jpudysz June 14, 2025 14:59
@danstepanov
Copy link
Collaborator

If @satya164 and @jpudysz are good with this then I am too

@danstepanov danstepanov requested review from satya164 and jpudysz June 28, 2025 17:54
Renamed type to better reflect that it represents the root navigator's
param list, not specifically a stack. This aligns with the Navigation
component naming convention.
Copy link

@satya164 satya164 left a comment

Choose a reason for hiding this comment

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

I have 2 suggestions - the one about theme is important, the other one is just a suggestion. But otherwise looks good to me.

- Use DarkTheme/DefaultTheme instead of merging with dark property
- Replace useEffect with Navigation onReady prop for SplashScreen
- Clean up theme selection with cleaner useMemo syntax
- Remove unused useEffect import from Tamagui section
@dannyhw
Copy link
Collaborator Author

dannyhw commented Jun 29, 2025

I believe this has now addressed all comments I think its ready to go @danstepanov

@danstepanov danstepanov merged commit 4a27460 into main Jun 29, 2025
1 check passed
@danstepanov danstepanov deleted the dannyhw/feat-static-react-navigation branch June 30, 2025 04:06
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.

4 participants