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

_forceRender() may not be defined in View when changing stories while the app is loaded #626

Open
trajano opened this issue Oct 21, 2024 · 0 comments

Comments

@trajano
Copy link
Contributor

trajano commented Oct 21, 2024

You just need to put in a default value in case it isn't set up yet in View.tsx just add

_forceRerender = () => {};

instead of

_forceRerender: () => void;

diff --git a/node_modules/@storybook/react-native/dist/index.js b/node_modules/@storybook/react-native/dist/index.js
index 78460b9..5811b7b 100644
--- a/node_modules/@storybook/react-native/dist/index.js
+++ b/node_modules/@storybook/react-native/dist/index.js
@@ -867,7 +867,7 @@ var View3 = class {
   _storyIndex;
   _setStory = () => {
   };
-  _forceRerender;
+  _forceRerender = () => {};
   _ready = false;
   _preview;
   _asyncStorageStoryId;
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

No branches or pull requests

1 participant