Closed tostr7191 closed 6 years ago
I am not sure why this is occurring. Perhaps it has to do with a quirk in your build environment. Do you have a custom .babelrc
set up, or are you using Haul or something?
We have changed the following in middleware.js
:
# removed at the bottom:
export {
createReactNavigationReduxMiddleware,
createDidUpdateCallback,
initializeListeners,
createNavigationPropConstructor,
};
# added export directly in front of the functions
Now it does no longer crash there. Our .babelrc
is nothing special I think:
{
"presets": ["react-native"]
}
Babel packages:
"devDependencies": {
"babel-cli": "^6.26.0",
"babel-core": "^6.26.3",
"babel-eslint": "^8.2.3",
"babel-jest": "23.0.1",
"babel-plugin-transform-runtime": "^6.23.0",
"babel-polyfill": "^6.23.0",
"babel-preset-env": "^1.7.0",
"babel-preset-react": "^6.24.1",
"babel-preset-react-native": "^4.0.0",
"babel-preset-stage-2": "^6.24.1",
<snip>
I see that it might be a problem on our side, but I can't really figure out where to look, do you see anything that's looking wrong from your perspective?
(We are using node v8.11.3
btw)
That's really weird. I can't imagine what's going wrong with the export syntax. You're sure there's nothing non-standard in your build system? You're using a stock react-native init
or create-react-native-app
config?
Hi
We have solved the problem, how exactly I can't really tell. But deleting the yarn.lock
file and reinstalling all packages made the problem disappear. Probably something messed up among some larger upgrades we have done that just happened to trigger this specific error!
Thanks for your help and sorry for the inconvenience :) tostr
Hi
Currently we are updating various packages in our app but it seems we struck a problem with you package:
We are running:
Are we missing something or is this a bug? I have tried numerous version combinations, the error moves around in the file but stays the same.
Thanks & Best tostr