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

fix(boilerplate): main entry point #2881

Merged
merged 1 commit into from
Jan 10, 2025
Merged

Conversation

frankcalise
Copy link
Contributor

@frankcalise frankcalise commented Jan 8, 2025

Please verify the following:

  • yarn test jest tests pass with new tests, if relevant
  • yarn lint eslint checks pass with new code, if relevant
  • yarn format:check prettier checks pass with new code, if relevant
  • README.md (or relevant documentation) has been updated with your changes
  • If this affects functionality there aren't tests for, I manually tested it, including by generating a new app locally if needed (see docs).

Describe your PR

Test Plan

Reproduction

  • Follow [https://ignitecookbook.com/docs/recipes/SettingUpYarnMonorepo](Setting Up Yarn Monorepo] cookbook recipe
    • Note: in doing so I had to make some touch ups to the recipe, which can be found in this PR if not yet published
  • Observe the Before screenshot below

Validation with plain Expo

  • Follow [https://docs.expo.dev/guides/monorepos/#create-our-first-app](monorepo guide)
  • Upon generating the app template, make sure to generate the app via npx create-expo-app@latest --template react-navigation/template to get a proper React Navigation template - otherwise expo-router will be used (which won't have this problem)

Updating Ignite

  • From the error state, modify the following:
    1. package.json, key main to App.tsx (an existing file)
    2. modify the contents of App.tsx to the following:
import "@expo/metro-runtime"
import { registerRootComponent } from "expo"
import * as SplashScreen from "expo-splash-screen"
import App from "@/app"

SplashScreen.preventAutoHideAsync()

function IgniteApp() {
  return <App hideSplashScreen={SplashScreen.hideAsync} />
}

registerRootComponent(IgniteApp)
  • Observe the After screenshot after running the app again

Screenshots (if applicable)

Before After
image image

@frankcalise frankcalise marked this pull request as ready for review January 8, 2025 15:41
Copy link
Collaborator

@flexbox flexbox left a comment

Choose a reason for hiding this comment

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

LGTM 🙌

@frankcalise frankcalise merged commit fe82fdb into master Jan 10, 2025
1 check passed
@frankcalise frankcalise deleted the frankcalise/fix-2875 branch January 10, 2025 13:55
infinitered-circleci pushed a commit that referenced this pull request Jan 10, 2025
## [10.1.2](v10.1.1...v10.1.2) (2025-01-10)

### Bug Fixes

* **boilerplate:** main entry point for monorepo ([#2881](#2881) by [@frankcalise](https://github.com/frankcalise)) ([fe82fdb](fe82fdb))
@infinitered-circleci
Copy link

🎉 This PR is included in version 10.1.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ignite expo mobile app in Yarn monorepo stuck in splash screen
3 participants