react-native-rss-parser
react-native-rss-parser copied to clipboard
Strict mode issue on Android
Environment details
React Native Environment Info:
System:
OS: macOS 10.14
CPU: (4) x64 Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
Memory: 46.32 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 11.9.0 - ~/.nvm/versions/node/v11.9.0/bin/node
Yarn: 1.13.0 - /usr/local/bin/yarn
npm: 6.5.0 - ~/.nvm/versions/node/v11.9.0/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 12.1, macOS 10.14, tvOS 12.1, watchOS 5.1
Android SDK:
API Levels: 26, 27, 28
Build Tools: 26.0.1, 26.0.2, 26.0.3, 27.0.3, 28.0.1
System Images: android-28 | Intel x86 Atom_64, android-28 | Google APIs Intel x86 Atom
IDEs:
Android Studio: 3.3 AI-182.5107.16.33.5314842
Xcode: 10.1/10B61 - /usr/bin/xcodebuild
npmPackages:
react: 16.5.0 => 16.5.0
react-native: 0.57.2 => 0.57.2
npmGlobalPackages:
react-native-cli: 2.0.1
react-native-svg: 9.3.7
Error
Expected
Application loads with no issue.
Actual
When executing the application on Android API 28
it throws an error: Strict mode does not allow function declaration in a lexically nested statement...
. If any reference to react-native-rss-parser
is removed from the application, it runs flawlessly.
Screenshot

Thanks for the detailed bug report (and sorry for the delay). I will need to try and reproduce this bug and then i can see if i can come up with a solution by fixing my function declarations. It seems like changes were done to babel to force this strict mode.
https://stackoverflow.com/questions/41058495/syntaxerror-strict-mode-does-not-allow-function-declarations-in-a-lexically-nes
I will post here once i find a solution
I am not able to reproduce this bug. If you are still using react-native-rss-parser
can you try upgrading to the newest version (v1.4.0) and see if it still has the problem. I did some code cleanup in this release.