-
-
Notifications
You must be signed in to change notification settings - Fork 320
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
Reanimated global.__reanimatedWorkletInit is not a function #182
Comments
same here. I tried using |
wcandillon/react-native-redash#395 (comment) |
same with react-native-gesture-handler: ^2.4.2 I see that mention before this issue. I will wait fix this |
I have the same problem. Reducing or upgrading the 'react-native-reanimated' version has no effect |
I have the same problem |
Same here! |
Same here |
Same here. Any workaround? |
this library is working fine on expo but it wasn't working for me with nextjs, however adding this somewhere high up the hierarchy (e.g. App.tsx) fixed it:
|
I have the same problem with EXPO, RN .68.2 |
Are there any help with this line? global.__reanimatedWorkletInit = () => {}; |
it work for me. If i put the code global.__reanimatedWorkletInit = () => {}; on '.../lib/commonjs/utils/dealWithAnimation.js works correctly Expo 45 |
If put it to your project will what happens? |
this problem was gone, and it works correctly. Solved for me. TypeError: global.__reanimatedWorkletInit is not a function. (In 'global.__reanimatedWorkletInit(_f)', 'global.__reanimatedWorkletInit' is undefined) |
I patched reanimated package 2.8.0 (by patch-package) and it's works for me: diff --git a/node_modules/react-native-reanimated/lib/reanimated2/core.js b/node_modules/react-native-reanimated/lib/reanimated2/core.js
index 284915e..b266740 100644
--- a/node_modules/react-native-reanimated/lib/reanimated2/core.js
+++ b/node_modules/react-native-reanimated/lib/reanimated2/core.js
@@ -2,6 +2,9 @@
import NativeReanimatedModule from './NativeReanimated';
import { Platform } from 'react-native';
import { nativeShouldBeMock, shouldBeUseWeb, isWeb } from './PlatformChecker';
+
+global.__reanimatedWorkletInit = () => { };
+
if (global._setGlobalConsole === undefined) {
// it can happen when Reanimated plugin wasn't added, but the user uses the only API from version 1
global._setGlobalConsole = () => { |
Having the same issue since update of expo SDK 45 |
Same problem here. All debugging instructions are ineffective |
I'm not able to make it work with your solution with expo SDK 45. |
I add
|
@thanhtrung07 |
patch did not work for me. Removing all calls to |
Since this error only happens on Expo SDK 45 I had to downgrade using |
Facing the same issue on Reanimated 2.8.0. Any update guys? Thanks |
Im working with Expo SDK and it require react-native-reanimated 2.8.0. I know downgrade to Reanimated 2.6.0 the issues fix, but i want somehelp with react-native-reanimated 2.8.0. Pls fix it. Thanks you. @dohooo |
* Fixing the react-native-reanimated-carousel error dohooo/react-native-reanimated-carousel#182 * Adding active account state
I released it in 2.6.0. This error is triggered by this PR, And there is related issue. In version 2.7.0+,
I think this should work with different versions of |
I get still this error, I cleared my cache, I added this code but nothing helps
|
You don't need to add this code, just upgrade the carousel version to 2.6.0 |
I updated it, but not working, anyone else has this problem ? I have to downgrade my reaniamted to 2.6.0 then its work, but I want the latest version |
Could try in this example? It used the latest version of reanimated. |
Seems to cause some big issues with webpack. I get the following error using it with RNW and Next.js 12.1: webpack_require.g.__reanimatedWorkletInit is not a function TypeError: webpack_require.g.__reanimatedWorkletInit is not a function FYI - 2.4.0 with calls to reanimatedWorklet removed via patch-package works fine. |
Hi, everyone. |
Thank you !!! |
Describe the bug
When i try use library with Expo, the follow message shows
TypeError: global.__reanimatedWorkletInit is not a function. (In 'global.__reanimatedWorkletInit(_f)', 'global.__reanimatedWorkletInit' is undefined)
If i put the code
global.__reanimatedWorkletInit = () => {};
on '.../lib/commonjs/utils/dealWithAnimation.js works correctly
To Reproduce
Steps to reproduce the behavior:
Screenshots
Versions:
Smartphone:
The text was updated successfully, but these errors were encountered: