Coder Social home page Coder Social logo

kanzitelli / expo-starter Goto Github PK

View Code? Open in Web Editor NEW
351.0 7.0 45.0 1.55 MB

🦥 Expo Starter - Powered by Expo SDK, Navio (React Navigation), RN UI lib, MMKV, Mobx, Reanimated 2, Dark Mode, Localization, and much more.

Home Page: https://starters.dev

TypeScript 97.89% JavaScript 2.11%
expo react-native mobx typescript expo-app react-navigation react react-native-starter expo-starter rn-navio

expo-starter's Introduction

This starter is a collection of libraries and approaches needed for fast start and productive maintainance of React Native (Expo) App.

Expo Starter is a part of starters.dev collection.

If Expo Starter helped you in any way, don't hesitate to ⭐️ the repo!

Getting Started

Quick start with cli-rn

npx cli-rn new app

In order to change app's name, please make necessary changes in app.json.

Manual setup
  1. Clone the repo
npx degit kanzitelli/expo-starter app
  1. Install packages
cd app && yarn
  1. Run it!
yarn start

What's inside

  • Expo SDK - a set of tools and services built around React Native and native platforms.
  • React Navigation (v6) - routing and navigation for React Native apps.
  • Navio - universal navigation library for React Native. Built on top of React Navigation.
  • RN UI lib - amazing Design System, UI toolset & components library for React Native. Dark Mode is implemented using this library.
  • Reanimated 2 - React Native's Animated library reimplemented.
  • React Native Gesture Handler - native touches and gesture system for React Native.
  • MobX - simple, scalable state management, with mobx-persist-store for persisting your stores.
  • Flash List - a better list for React Native (by Shopify).
  • Expo Image - cross-platform React component that loads and renders images.

Native libraries

In order to use them, you will need to run yarn prebuild command to generate ios/ and android/ folders with native code.

  • MMKV - efficient, small mobile key-value storage framework developed by WeChat. ~30x faster than AsyncStorage! Available only within Expo dev clients. Instructions on installation could be found here.

Useful services/methods

  • navio - a service that exposes all navigation methods of Navio instance.
  • translate - a service that brings an easy integration of localization for an app by using i18n-js and expo-localization.
  • api - a service where API-related methods are located.
  • onStart - a service where you can write your own logic when app is launched. For example, you can increment number of appLaunches there.

Design system

This starter is using RN UI lib as a design system, UI toolset and a source of ready-to-go components.

configureDesignSystem() - a method where all settings for an app's design system is taking place. You can customize colors, schemes, typegraphy, spacings, etc. Located at src/utils/designSystem.tsx.

video.MP4

Advantages

Build app layout in one place with Navio

All setup for your screens, tabs and modals take place in one file src/screens/index.ts.

import {Navio} from 'rn-navio';

// importing screen components
import {Main} from '@app/screens/main';
import {Playground} from '@app/screens/playground';
import {Settings} from '@app/screens/settings';
import {Example} from '@app/screens/_screen-sample';

// building layout
export const navio = Navio.build({
  screens: {
    Main,
    Settings,
    Example,
    Playground: {
      component: Playground,
      options: () => ({
        title: 'Playground',
      }),
    },
  },
  stacks: {
    MainStack: ['Main', 'Example'],
    ExampleStack: {
      screens: ['Example'],
      navigatorProps: {
        screenListeners: {
          focus: () => {},
        },
      },
    },
  },
  tabs: {
    AppTabs: {
      layout: {
        MainTab: {
          stack: 'MainStack',
          options: () => ({
            title: 'Main',
            tabBarIcon: getTabBarIcon('MainTab'),
          }),
        },
        PlaygroundTab: {
          stack: ['Playground'],
          options: () => ({
            title: 'Playground',
            tabBarIcon: getTabBarIcon('PlaygroundTab'),
          }),
        },
        SettingsTab: {
          stack: ['Settings'],
          options: () => ({
            title: services.t.do('settings.title'),
            tabBarIcon: getTabBarIcon('SettingsTab'),
          }),
        },
      },
    },
  },
  modals: {
    ExampleModal: {stack: 'ExampleStack'},
  },
  drawers: {
    MainDrawer: {
      layout: {
        Main: 'MainStack',
        Example: 'ExampleStack',
        Playground: ['Playground'],
      },
    },
  },
  root: 'AppTabs',
});

export const NavioApp = navio.App;

Navigate with predictability

export const Screen = () => {
  const {navio} = useServices();

  return (
    <View>
      <Button
        label="Push Settings"
        onPress={() => {
          // Typescript and IDE will help with autocompletion
          navio.push('Settings');
        }}
      />
    </View>
  );
};

App flows

You can find different app flows, such as Auth flow, simple 2 screens, 3 tabs, etc., in the navio.tsx.

Dark mode

You can define modes in designSystem.tsx.

Samples for new screens, services, stores and components.

So you have one structure within the project. You can find them in corresponding folders. Just copy&paste it and make the necessary changes.

Enhancements

There are still some things I would like to add to the starter:

Feel free to open an issue for suggestions.

Worth checking

Other starters

  • rnn-starter - 🤹 Production-ready starter for React Native App! Powered by cli-rn, React Native Navigation, RN UI lib, Mobx, Reanimated 2, Dark Mode, Localization, Notifications, Permissions, and much more.
  • rn-starter - 🦄 Production-ready starter for React Native App! Powered by cli-rn, React Navigation (v6), RN UI lib, Mobx, Reanimated 2, Dark Mode, Localization, Notifications, Permissions, and much more.

Icons have been generated with BuildIcon created by Evan Bacon.

Articles

  • "Build React Native Apps with Simplified and Predictable Navigation" - Medium, Dev.to
  • "Testing React Native apps with zero effort" - Medium, Dev.to
  • "Expo + React Native Navigation? Yes!" - Medium, Dev.to

Why

...do we need yet another starter/boilerplate? Well, I work with React Native for more than 4 years and during the time I started having my own project structure which was a good fit for almost all of the delivered apps. Also, I have come up with some custom useful services/methods which simplify usage of React Navigation and other libraries. Check out Advantages section.

License

This project is MIT licensed

expo-starter's People

Contributors

kanzitelli avatar revolt9k avatar swrzalek avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

expo-starter's Issues

expo production build error

Hello! I am having an issue creating a production build for android in my app.

I also tried creating a brand new code base with npx cli-rn new newProject and had the same issue without modifying the generated code.

I'm running eas build --platform android, and the build fails with these logs at the end:

> Task :app:createBundleReleaseJsAndAssets
warning: the transform cache was reset.
Welcome to Metro v0.73.9
              Fast - Scalable - Integrated
> Task :expo-updates:createReleaseExpoManifest FAILED
[stderr] 
Error: @build-script-error-begin
[stderr] 
Error loading assets JSON from Metro. Ensure you've followed all expo-updates installation steps correctly. node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: helperSkipTransparentExpressionWrappers.skipTransparentExprWrapperNodes is not a function
[stderr] 
@build-script-error-end
[stderr] 
    at /home/expo/workingdir/build/node_modules/expo-updates/scripts/createManifest.js:59:11
[stderr] 
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
> Task :react-native-picker_picker:compileReleaseJavaWithJavac
[stderr] 
Note: Some input files use or override a deprecated API.
[stderr] 
Note: Recompile with -Xlint:deprecation for details.
> Task :react-native-async-storage_async-storage:compileReleaseJavaWithJavac
> Task :react-native-community_masked-view:compileReleaseJavaWithJavac
[stderr] 
Note: /home/expo/workingdir/build/node_modules/@react-native-async-storage/async-storage/android/src/main/java/com/reactnativecommunity/asyncstorage/AsyncStorageModule.java uses or overrides a deprecated API.
[stderr] 
Note: Recompile with -Xlint:deprecation for details.
[stderr] 
Note: /home/expo/workingdir/build/node_modules/@react-native-async-storage/async-storage/android/src/main/java/com/reactnativecommunity/asyncstorage/AsyncStoragePackage.java uses unchecked or unsafe operations.
[stderr] 
Note: Recompile with -Xlint:unchecked for details.
> Task :expo-dev-client:compileReleaseJavaWithJavac
> Task :app:createBundleReleaseJsAndAssets
TypeError: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: helperSkipTransparentExpressionWrappers.skipTransparentExprWrapperNodes is not a function
    at transform (/home/expo/workingdir/build/node_modules/@babel/plugin-proposal-optional-chaining/lib/index.js:123:59)
    at PluginPass.OptionalCallExpression|OptionalMemberExpression (/home/expo/workingdir/build/node_modules/@babel/plugin-proposal-optional-chaining/lib/index.js:206:9)
    at newFn (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/visitors.js:149:21)
    at NodePath._call (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:45:20)
    at NodePath.call (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:35:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:80:31)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitSingle (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:65:19)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:109:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitMultiple (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:61:17)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:107:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitSingle (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:65:19)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:109:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitMultiple (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:61:17)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:107:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitSingle (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:65:19)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:109:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitSingle (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:65:19)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:109:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitMultiple (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:61:17)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:107:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at NodePath.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/path/context.js:86:52)
    at TraversalContext.visitQueue (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:86:16)
    at TraversalContext.visitSingle (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:65:19)
    at TraversalContext.visit (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/context.js:109:19)
    at traverseNode (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/traverse-node.js:18:17)
    at traverse (/home/expo/workingdir/build/node_modules/@babel/traverse/lib/index.js:49:34)
    at transformFile (/home/expo/workingdir/build/node_modules/@babel/core/lib/transformation/index.js:81:29)
    at transformFile.next (<anonymous>)
    at run (/home/expo/workingdir/build/node_modules/@babel/core/lib/transformation/index.js:24:12)
[stderr] 
error node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: /home/expo/workingdir/build/node_modules/react-native-gesture-handler/src/handlers/gestures/GestureDetector.tsx: helperSkipTransparentExpressionWrappers.skipTransparentExprWrapperNodes is not a function
> Task :app:createBundleReleaseJsAndAssets FAILED
> Task :expo-modules-core:compileReleaseKotlin
w: Argument -Xopt-in is deprecated. Please use -opt-in instead
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/adapters/react/permissions/PermissionsService.kt:157:30 'getPackageInfo(String, Int): PackageInfo!' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/core/utilities/EmulatorUtilities.kt:30:13 'SERIAL: String!' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/Promise.kt:68:18 This declaration overrides deprecated member but not marked as deprecated itself. This deprecation won't be inherited in future releases. Please add @Deprecated annotation or suppress. See https://youtrack.jetbrains.com/issue/KT-47902 for details
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/ActivityResultsManager.kt:52:24 Parameter 'activity' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/AppContextActivityResultRegistry.kt:119:51 'getParcelableExtra(String!): T?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/AppContextActivityResultRegistry.kt:180:26 'getParcelable(String?): T?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/AppContextActivityResultRegistry.kt:271:83 'getParcelable(String?): T?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/DataPersistor.kt:67:20 'getSerializable(String?): Serializable?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/activityresult/DataPersistor.kt:85:26 'getSerializable(String?): Serializable?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/events/KModuleEventEmitterWrapper.kt:90:7 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/jni/JavaScriptObject.kt:59:33 Parameter 'null' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/jni/JavaScriptObject.kt:100:5 Parameter 'null' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/modules/Module.kt:43:7 'coroutineScope: CoroutineScope' is deprecated. Use a scope from the AppContext
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/types/Either.kt:24:11 Parameter 'type' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/types/Either.kt:27:11 Parameter 'type' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/types/Either.kt:44:11 Parameter 'type' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/types/Either.kt:59:11 Parameter 'type' is never used
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/types/JSTypeConverterHelper.kt:44:17 'get(String!): Any?' is deprecated. Deprecated in Java
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/views/ViewManagerDefinitionBuilder.kt:125:30 'ViewGroupDefinitionLegacyBuilder' is deprecated. Use `ViewGroupDefinitionBuilder` instead.
w: file:///home/expo/workingdir/build/node_modules/expo-modules-core/android/src/main/java/expo/modules/kotlin/views/ViewManagerDefinitionBuilder.kt:128:38 'ViewGroupDefinitionLegacyBuilder' is deprecated. Use `ViewGroupDefinitionBuilder` instead.
[stderr] 
FAILURE: Build completed with 3 failures.
[stderr] 
1: Task failed with an exception.
[stderr] 
-----------
[stderr] 
* What went wrong:
[stderr] 
Execution failed for task ':expo-updates:createReleaseExpoManifest'.
[stderr] 
> Process 'command 'node'' finished with non-zero exit value 1
[stderr] 
* Try:
[stderr] 
> Run with --stacktrace option to get the stack trace.
[stderr] 
> Run with --info or --debug option to get more log output.
[stderr] 
> Run with --scan to get full insights.
[stderr] 
==============================================================================
[stderr] 
2: Task failed with an exception.
[stderr] 
-----------
[stderr] 
* What went wrong:
[stderr] 
java.lang.StackOverflowError (no error message)
[stderr] 
* Try:
[stderr] 
> Run with --stacktrace option to get the stack trace.
[stderr] 
> Run with --info or --debug option to get more log output.
[stderr] 
> Run with --scan to get full insights.
[stderr] 
==============================================================================
[stderr] 
3: Task failed with an exception.
[stderr] 
-----------
[stderr] 
* What went wrong:
[stderr] 
Execution failed for task ':app:createBundleReleaseJsAndAssets'.
[stderr] 
> Process 'command 'node'' finished with non-zero exit value 1
[stderr] 
* Try:
[stderr] 
> Run with --stacktrace option to get the stack trace.
[stderr] 
> Run with --info or --debug option to get more log output.
[stderr] 
> Run with --scan to get full insights.
[stderr] 
==============================================================================
[stderr] 
* Get more help at https://help.gradle.org
[stderr] 
BUILD FAILED in 4m 7s
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.5.1/userguide/command_line_interface.html#sec:command_line_warnings
296 actionable tasks: 296 executed
Error: Gradle build failed with unknown error. See logs for the "Run gradlew" phase for more information.

Any help is greatly appreciated! Thanks!

upgrade to rnuilib v7

I'm about to start a new project and was wondering if by any chance this is happening in the near future.

Great starter btw. Was tinkering with it a little and i like the structure very much 👍🏻

how to import assets

i couldn't figure out how to import assets in this project, what i ended up doing was:

  1. put my assets (like .pngs) in assets dir,
  2. added this to tsconfig.json
"paths": {
    ...,
    "@assets/*": [
        "assets/*"
    ]
}
  1. created a react-app-env.d.ts inside src dir:
declare module "*.png";
declare module "*.svg";
declare module "*.jpeg";
declare module "*.jpg";

and finally i could import my assets:

import examplePng from "@assets/example.png"

but i am wondering if i did too much work and there's another intended way to do this? i figured there might be something i missed in the starter project if this was taken into consideration, thanks!

Possible Unhandled Promise Rejection (id:0)

When try to change the UI > Language > Sysytem ----> English
in Expo run:ios -d (Device Xxxx)
It doesn't work, just in IOS Simulator

[Unhandled promise rejection: Error: You cannot use the Updates module in development mode in a production app. To test manual updates, make a release build with npm run ios --configuration Release or npm run android --variant Release.]
at http://192.168.1.13:8081/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:102793:321 in _createSuperInternal
at node_modules/expo-modules-core/build/errors/CodedError.js:10:8 in constructor
at http://192.168.1.13:8081/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:233273:49 in reloadAsync$
at node_modules/expo-updates/build/Updates.js:88:7 in reloadAsync
at src/services/navigation/index.ts:40:12 in Nav#restart
at src/services/navigation/index.ts:40:12 in Nav#restart
at src/stores/ui.ts:39:9 in UIStore#setLanguage
at node_modules/mobx/dist/mobx.esm.js:1255:11 in executeAction
at node_modules/mobx/dist/mobx.esm.js:1239:24 in res
at src/screens/settings.tsx:51:53 in
at node_modules/react-native-ui-lib/src/components/actionSheet/index.js:125:4 in ActionSheet#onOptionPress

How to pass variable to stack

@kanzitelli Thank you for the cool updates and navio library. As i'm using navio i have
few question to ask. so thought to trouble you.

export const navio = Navio.build({
  screens: {
    TabOneScreen: {
      component: TabOneScreen,
      options: () => ({
        title: services.t.do(''),
        ...screenDefaultOptions(),
      }),
    },
    ProductDetailScreen: {
      component: ProductDetailScreen,
      options: {
        headerShown: false,
      },
    },
  },
  HomeStack: {
    screens: ['TabOneScreen'],
    containerOptions: {
      headerShown: true,
      title: '',
    },
  },
  ProductStack: {
    screens: ['ProductDetailScreen'],
    containerOptions: {
      headerShown: true,
      title: 'Product page',
    },
  },
  tabs: {
    AppTabs: {
      content: {
        HomeTab: {
          stack: 'HomeStack',
          options: () => ({
            title: services.t.do(''),
            tabBarIcon: getTabBarIcon('HomeTab'),
          }),
        },
      },
    },
  },
});

i have this screen setup and imagine my TabOneScreen had
products and when i click a product im calling this function
navio.stacks.push('ProductStack'). is there anyway to pass the
productId to the ProductDetailScreen and also how to update the title to
product name dynamically?

also in ProductDetailScreen i want to show right
button only if the user is logged just like below. but it doesn't show
what is the best approach here?

export const ProductDetailScreen: NavioScreen = observer(() => {
  //navigation buttons
  const configureUI = () => {
    navigation.setOptions({
      headerRight: () =>
        authUser.User.isLogin && (
          <Row>
            <HeaderBImage
              assetName='bookMark'
              assetGroup='product'
              onPress={() => {
                productViolationModalRef.current.open();
              }}
            />
          </Row>
        ),
    });
  };

  useEffect(() => {
    configureUI();
  }, []);

  return ()
});

ApiV2Error: Entity Not Authorized

Hello,
I'm using Manual mode to run this starter but I'm getting this message after iOS simulator opens.
ApiV2Error: Entity Not Authorized
iOS 16 with iPhone 14 and 14 Pro Max
MacOS & XCode: Latest

yarn start --web

yarn start --web

cRtdCKV8tO

Uncaught Error: Module parse failed: Unexpected token (16:10)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|     // | Vars |
|     // ========
>     layout;
|     navRef;
|     navIsReadyRef;
    at ./node_modules/rn-navio/dist/index.js (index.js:120:1)
    at __webpack_require__ (bootstrap:789:1)
    at fn (bootstrap:100:1)
    at ./src/screens/index.tsx (index.tsx:1:1)
    at __webpack_require__ (bootstrap:789:1)
    at fn (bootstrap:100:1)
    at ./App.tsx (bootstrap:856:1)
    at __webpack_require__ (bootstrap:789:1)
    at fn (bootstrap:100:1)
    at ./node_modules/expo/AppEntry.js (AppEntry.js:1:1)
    at __webpack_require__ (bootstrap:789:1)
    at fn (bootstrap:100:1)
    at 1 (enums.ts:42:1)
    at __webpack_require__ (bootstrap:789:1)
    at bootstrap:856:1
    at bootstrap:856:1
./node_modules/rn-navio/dist/index.js 16:10
Module parse failed: Unexpected token (16:10)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|     // | Vars |
|     // ========
>     layout;
|     navRef;
|     navIsReadyRef;
console.<computed> @ index.js:1
Uncaught ReferenceError: process is not defined
    at 4043 (<anonymous>:2:13168)
    at r (<anonymous>:2:306599)
    at 8048 (<anonymous>:2:9496)
    at r (<anonymous>:2:306599)
    at 8641 (<anonymous>:2:1379)
    at r (<anonymous>:2:306599)
    at <anonymous>:2:315627
    at <anonymous>:2:324225
    at <anonymous>:2:324229
    at e.onload (index.js:1:1)

node v16.18.1

How to pop to the first screen of the stack when the user presses the back button

Dear @kanzitelli Thank you as always, I have learned lot from you.

Here, Let's say i have Tab based application. In the profile tab i have "settings" button. If the user
presses the "settings" button. i'm taking the user to the "SettingStack". since the first screen of the stack is
"SettingScreen" the app displays the "SettingScreen" screen.

Now, the problem is while i'm on the "Settings" screen, if i push "CreateCollectionScreen" to the Stack and from the
"CreateCollectionScreen" if i go back it goes to the "ProfileTab".

Here what i want to do is while on the "CreateCollectionScreen" if i go back i want it to pop to the first screen of the stack
which is "Settings" screen.

alternatively i could show a modal for each menu in the setting screen. which i really want to avoid, because
i would like get all the possible spaces available to me on certain cases.

Is this possible?

export const navio = Navio.build({
  screens: {
    ...
  },
  stacks: {
    SettingStack: {
      screens: [
        'SettingScreen',
        'CreateCollectionScreen',
        'LanguageScreen',
        'ThemeScreen',
        'ProfileEditScreen',
        'UserLocUpdateScreen',
      ],
      containerOptions: {
        headerShown: true,
        title: 'Settings',
      },
    },
    ...
  },
  tabs: {
    AppTabs: {
      content: {
        ...
        ProfileTab: {
          stack: 'ProfileStack',
          options: () => ({
            title: 'Profile',
            tabBarIcon: 'icon'
          }),
        },
      },
    },
  },
});

route props on options

Hi,
If you want write custom title with route props thats a problem. How can i solved it??

Example

Main: { name: 'Main', component: Main, options: ({ route }) => ({ title: route.params.title, ...screenDefaultOptions(), }), },

I think the problem is here...
type ScreenInfo = BaseScreenInfo & { options: () => NativeStackNavigationOptions; };

Require cycle error is it important?

Hello i get this errors in starter

Require cycle: src/services/index.tsx -> src/services/onStart.ts -> src/stores/index.tsx -> src/stores/ui.ts -> src/services/index.tsx

Require cycles are allowed, but can result in uninitialized values. Consider refactoring to remove the need for a cycle.
at node_modules/metro-runtime/src/polyfills/require.js:117:6 in metroRequire
at http://192.168.28.85:8081/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:231795:29 in anonymous
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at http://192.168.28.85:8081/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:230364:23 in anonymous
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at src/services/onStart.ts:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at src/services/index.tsx:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at src/screens/main.tsx:7:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at src/screens/index.ts:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at src/app.tsx:5:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at App.tsx:7:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:210:35 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at node_modules/expo/AppEntry.js:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:349:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:201:44 in guardedLoadModule
at node_modules/metro-runtime/src/polyfills/require.js:128:23 in metroRequire
at http://192.168.28.85:8081/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:239353:3 in global

RCTBridge required dispatch_sync to load RNGestureHandlerModule. This may lead to deadlocks
- ... 6 more stack frames from framework internals

I am not sure if they are important errors.

Thanks

Log In Screen

What is the correct way of implementing a login screen in this template?
I have tried storing the logged in user in a store, and using a conditional render in the RootNavigator but I am having errors.

// Root Navigator
export const RootNavigator: React.FC =  observer(({}) => {
  const {auth} = useStores();
  console.log('regenrated', auth.currentUser);
  if (auth.currentUser != null)
  {
    return genRootNavigator(TabNavigator, [modals.ExampleModal]);
  }
  else
  {
    return LoginStack();
  }
});

TypeError: undefined is not an object (evaluating '_stores.stores.ui')

Hi. I'm using the template, so far I love it but have been encountering a warning and uncaught error lately and am not sure what the cause of it is cause they just pop up out of nowhere.

warning:
Require cycle: src/stores/index.tsx -> src/stores/ui.ts -> src/services/index.tsx -> src/services/onStart.ts -> src/stores/index.tsx
error:
TypeError: undefined is not an object (evaluating '_stores.stores.ui')

Can I do auth flow like below?

screens/index.tsx

// NAVIO
export const navio = Navio.build({
  screens: {
    Main,
    Settings,
    Example,
    Login,
    Register,
    Playground: {
      component: Playground,
      options: () => ({
        title: 'Playground',
      }),
    },
  },
  stacks: {
    MainStack: ['Main', 'Example'],
    ExampleStack: ['Example'],
    LoginStack: ['Login', 'Register'],
  },
  tabs: {
    MainTab: {
      stack: 'MainStack',
      options: {
        title: 'Home',
        tabBarIcon: getTabBarIcon('MainTab'),
      },
    },
    PlaygroundTab: {
      stack: ['Playground'],
      options: () => ({
        title: 'Playground',
        tabBarIcon: getTabBarIcon('PlaygroundTab'),
      }),
    },
    SettingsTab: {
      stack: ['Settings'],
      options: () => ({
        title: 'Settings',
        tabBarIcon: getTabBarIcon('SettingsTab'),
      }),
    },
  },
  modals: {
    ExampleModal: 'ExampleStack',
  },
  root: 'Tabs',
  hooks: [useAppearance],
  options: {
    stack: screenDefaultOptions,
    tab: tabDefaultOptions,
  },
});





export const getNavio = () => navio;
export const AppRoot = navio.Root;

App.tsx

//auth network request
function delay(){
  return new Promise((resolve)=>{
    setTimeout(() => {
      resolve({})
    }, 1000);
  })
}
export default (): JSX.Element => {
  useAppearance();
  const [ready, setReady] = useState(false);
  const [isLogin, setIsLogin] = useState(false);

  const start = useCallback(async () => {
    await SplashScreen.preventAutoHideAsync();

    await hydrateStores();
    configureDesignSystem();
    await initServices();
    await delay()
    setIsLogin(false)

    setReady(true);
  
    await delay()
    await SplashScreen.hideAsync();

       
   
  }, []);

  useEffect(() => {
    start();
  }, [start]);

  if (!ready) return <></>;
  return (
    <GestureHandlerRootView style={{flex: 1}}>
      <SSProvider>
        <StatusBar style={getStatusBarStyle()} backgroundColor={getStatusBarBGColor()} />
        <AppRoot initialRouteName={isLogin ? 'Tabs':'LoginStack'} navigationContainerProps={{theme: getNavigationTheme()}} />
      </SSProvider>
    </GestureHandlerRootView>
  );
};


Update dependecies

When I used this starter, I got two warnings. Propose you to update it, to make it easier for others.

 - expo-dev-client - expected version: ~0.8.6 - actual version installed: 0.8.4
 - expo-updates - expected version: ~0.11.7 - actual version installed: 0.11.6

P.S. expo doctor --fix-dependencies

"Store.name" creates duplicates once published

Newbie here!

Once code has been published some SomeStore.name are possibly duplicated and causes issue on hydrateStores.

Noticed this while creating multiple IStore classes. The app keeps getting stuck on splash screen in Production mode and failing at hydrateStores, and then I tried logging store each store loop iteration under said method and noticed t is being hydrated multiple times hence failing to hydrate one or more stores properply. The same code works fine in dev mode (probably because names aren't minified here).

Am I doing something wrong? Or any configurations I might've missed?


Worked around the issue by hard-coding name instead of using Function.name.

From:

export class SampleStore implements IStore {
  
   ...
  
    makePersistable(this, {
      name: SampleStore.name,
      properties: ['someProperty'],
    });

  ...

To:

    makePersistable(this, {
      name: "SampleStore",
      properties: ['someProperty'],
    });

Deep linking support

Thank you for creating this fantastic resource! 🙏

In my codebase, I have something like this for deep linking

import { NavigationContainer } from '@react-navigation/native';

function App() {
  const linking = {
    prefixes: ['https://mychat.com', 'mychat://'],
    config: {
      screens: {
        Home: 'feed/:sort',
      },
    },
  };

  return (
    <NavigationContainer linking={linking} fallback={<Text>Loading...</Text>}>
      {/* content */}
    </NavigationContainer>
  );
}

With the latest version of expo-started, I noticed that it is using a rn-navio library. But there is no way to provide custom linking prop. This is very crucial for production apps.

https://reactnavigation.org/docs/navigation-container/#linking
https://docs.expo.dev/guides/deep-linking/

Newbie questions (mmkv, auth)

Hey @kanzitelli,

my goal is to create a simple note taking app that saves the data on the users device, but the user can also log in and share it on a wall.
I also want to add a meditation feature in the app to make it more unique (I would use reanimated and mmkv).
My main goal with the app is to put it in my portfolio, that I can use to find a job finally.

So thats about the me, but the details:

  1. I see that the MMKV part is commented. If I want to use it for the notes, should I just uncomment those parts and its done?
  2. Should I use MMKV storages for both the auth and notes so I mean, when should I use it and when not?
  3. If I wanted to use a regular expo-google-auth combination, I just used this article: https://docs.expo.dev/guides/google-authentication/ (expo-auth-session, expo-crypto, expo-web-browser)
    Now I'm a bit lost on how should I do that. Could you give me some instructions?

Thanks in ordnung for your answer!

Mobx frozen Error

I am not sure if its right place to ask that error. I have a local file link mobx persisted state. A image component gets that file link from mobx state. But application crashes. I have tried with both vanilla rn image component and rnuilib image component.

Error: [MobX] Observable arrays cannot be frozen

This error is located at:
    in RCTImageView
    in Image (created by wrappedComponent)
    in RCTView (created by View)
    in View (created by AnimatedComponent)
    in AnimatedComponent
    in AnimatedComponentWrapper (created by TouchableOpacity)
    in TouchableOpacity
    in Unknown (created by TouchableOpacity)
    in TouchableOpacity (created by TouchableOpacity)
    in TouchableOpacity (created by TouchableOpacity)
    in TouchableOpacity (created by TouchableOpacity)
    in TouchableOpacity (created by wrappedComponent)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by wrappedComponent)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by wrappedComponent)
    in wrappedComponent (created by Match)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by Match)
    in ViewManagerAdapter_ExpoLinearGradient
    in Adapter<ExpoLinearGradient> (created by LinearGradient)
    in LinearGradient (created by _c)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by _c)
    in RCTScrollContentView (created by ScrollView)
    in RCTScrollView (created by ScrollView)
    in ScrollView (created by ScrollView)
    in ScrollView (created by NativeViewGestureHandler)
    in NativeViewGestureHandler (created by ScrollView)
    in ScrollView (created by _c)
    in _c (created by Match)
    in Match (created by SceneView)
    in StaticContainer
    in EnsureSingleNavigator (created by SceneView)
    in SceneView (created by SceneView)
    in RCTView (created by View)
    in View (created by DebugContainer)
    in DebugContainer (created by MaybeNestedStack)
    in MaybeNestedStack (created by SceneView)
    in RNSScreen (created by AnimatedComponent)
    in AnimatedComponent
    in AnimatedComponentWrapper (created by Screen)
    in MaybeFreeze (created by Screen)
    in Screen (created by SceneView)
    in SceneView (created by NativeStackViewInner)
    in RNSScreenStack (created by ScreenStack)
    in ScreenStack (created by NativeStackViewInner)
    in NativeStackViewInner (created by NativeStackView)
    in RCTView (created by View)
    in View (created by SafeAreaInsetsContext)
    in SafeAreaProviderCompat (created by NativeStackView)
    in NativeStackView (created by NativeStackNavigator)
    in NativeStackNavigator (created by HomeStack)
    in HomeStack (created by SceneView)
    in StaticContainer
    in EnsureSingleNavigator (created by SceneView)
    in SceneView (created by SceneView)
    in RCTView (created by View)
    in View (created by DebugContainer)
    in DebugContainer (created by MaybeNestedStack)
    in MaybeNestedStack (created by SceneView)
    in RNSScreen (created by AnimatedComponent)
    in AnimatedComponent
    in AnimatedComponentWrapper (created by Screen)
    in MaybeFreeze (created by Screen)
    in Screen (created by SceneView)
    in SceneView (created by NativeStackViewInner)
    in RNSScreenStack (created by ScreenStack)
    in ScreenStack (created by NativeStackViewInner)
    in NativeStackViewInner (created by NativeStackView)
    in RNCSafeAreaProvider (created by SafeAreaProvider)
    in SafeAreaProvider (created by SafeAreaInsetsContext)
    in SafeAreaProviderCompat (created by NativeStackView)
    in NativeStackView (created by NativeStackNavigator)
    in NativeStackNavigator (created by RootNavigator)
    in RootNavigator (created by AppNavigator)
    in EnsureSingleNavigator
    in BaseNavigationContainer
    in ThemeProvider
    in NavigationContainerInner (created by AppNavigator)
    in AppNavigator
    in ServicesProvider
    in StoresProvider
    in RCTView (created by View)
    in View (created by GestureHandlerRootView)
    in GestureHandlerRootView
    in Unknown (created by ExpoRoot)
    in ExpoRoot
    in RCTView (created by View)
    in View (created by AppContainer)
    in RCTView (created by View)
    in View (created by AppContainer)
    in AppContainer, js engine: hermes
- ... 32 more stack frames from framework internals`
Warning: Failed prop type: Invalid prop `source` supplied to `Image`.
    at Image (http://192.168.28.85:8081/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:68764:42)
    in wrappedComponent (created by Match)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by Match)
    in ViewManagerAdapter_ExpoLinearGradient
    in Adapter<ExpoLinearGradient> (created by LinearGradient)
    in LinearGradient (created by _c)
    in RCTView (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by View)
    in View (created by _c)
    in RCTScrollContentView (created by ScrollView)
    in RCTScrollView (created by ScrollView)
    in ScrollView (created by ScrollView)
    in ScrollView (created by NativeViewGestureHandler)
    in NativeViewGestureHandler (created by ScrollView)
    in ScrollView (created by _c)
    in _c (created by Match)
    in Match (created by SceneView)
    in StaticContainer
    in EnsureSingleNavigator (created by SceneView)
    in SceneView (created by SceneView)
    in RCTView (created by View)
    in View (created by DebugContainer)
    in DebugContainer (created by MaybeNestedStack)
    in MaybeNestedStack (created by SceneView)
    in RNSScreen (created by AnimatedComponent)
    in AnimatedComponent
    in AnimatedComponentWrapper (created by Screen)
    in MaybeFreeze (created by Screen)
    in Screen (created by SceneView)
    in SceneView (created by NativeStackViewInner)
    in RNSScreenStack (created by ScreenStack)
    in ScreenStack (created by NativeStackViewInner)
    in NativeStackViewInner (created by NativeStackView)
    in RCTView (created by View)
    in View (created by SafeAreaInsetsContext)
    in SafeAreaProviderCompat (created by NativeStackView)
    in NativeStackView (created by NativeStackNavigator)
    in NativeStackNavigator (created by HomeStack)
    in HomeStack (created by SceneView)
    in StaticContainer
    in EnsureSingleNavigator (created by SceneView)
    in SceneView (created by SceneView)
    in RCTView (created by View)
    in View (created by DebugContainer)
    in DebugContainer (created by MaybeNestedStack)
    in MaybeNestedStack (created by SceneView)
    in RNSScreen (created by AnimatedComponent)
    in AnimatedComponent
    in AnimatedComponentWrapper (created by Screen)
    in MaybeFreeze (created by Screen)
    in Screen (created by SceneView)
    in SceneView (created by NativeStackViewInner)
    in RNSScreenStack (created by ScreenStack)
    in ScreenStack (created by NativeStackViewInner)
    in NativeStackViewInner (created by NativeStackView)
    in RNCSafeAreaProvider (created by SafeAreaProvider)
    in SafeAreaProvider (created by SafeAreaInsetsContext)
    in SafeAreaProviderCompat (created by NativeStackView)
    in NativeStackView (created by NativeStackNavigator)
    in NativeStackNavigator (created by RootNavigator)
    in RootNavigator (created by AppNavigator)
    in EnsureSingleNavigator
    in BaseNavigationContainer
    in ThemeProvider
    in NavigationContainerInner (created by AppNavigator)
    in AppNavigator
    in ServicesProvider
    in StoresProvider
    in RCTView (created by View)
    in View (created by GestureHandlerRootView)
    in GestureHandlerRootView
    in Unknown (created by ExpoRoot)
    in ExpoRoot
    in RCTView (created by View)
    in View (created by AppContainer)
    in RCTView (created by View)
    in View (created by AppContainer)
    in AppContainer
at node_modules/react/cjs/react-jsx-runtime.development.js:117:4 in printWarning
at node_modules/react/cjs/react-jsx-runtime.development.js:93:16 in error
at node_modules/react/cjs/react-jsx-runtime.development.js:620:15 in checkPropTypes
at node_modules/react/cjs/react-jsx-runtime.development.js:1072:20 in validatePropTypes
at node_modules/react/cjs/react-jsx-runtime.development.js:1192:23 in jsxWithValidation
at node_modules/react/cjs/react-jsx-runtime.development.js:1209:28 in jsxWithValidationDynamic
at http://192.168.28.85:8081/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:299210:42 in anonymous
at node_modules/mobx-react-lite/es/observer.js:24:61 in useObserver$argument_0
at node_modules/mobx-react-lite/es/useObserver.js:111:26 in reaction.track$argument_0
- ... 28 more stack frames from framework internals

Previously i was using redux toolkit, it was working fine. Then i moved expo-starter. Now crashes.

Hide tab bar for specific screen.

Hi,
I know this is not related to the repo. but the way things are setup. i would like to know how to hide
tab bar for specific screens

Screenshot 2022-09-24 at 21 16 25

Params doesn't seem to work.

When pushing with params, the params never seem to be available. For instance using this repo, when changing these params:

const pushScreen = () => navio.push('Example', {type: 'push'});

You'd expect the type value to change here:

export const Example: NavioScreen<Props> = observer(({type = 'push'}) => {

However it never changes, and simply changing it to a props and logging it shows that its receiving a far different object to what is expected (a route object if I'm not mistaken).

Changing the language or appearance crashes the app in release build

Hi, I was using your code as a boilerplate for my app and faced this issue in which changing the language or appearance crashes the app in release build. The app works fine while development in expo or expo go but after creating a release build, it crashes the app and the mobx store gets emptied too. It seems like reloadAsync used is not functioning properly. I was wondering if you have faced this issue and if you did, how did you resolved it or is there any alternative to reloadAsync that you used because I tried everything but got no luck. Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.