You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Object.hasOwn is not implemented in the version of JSC shipped with RN Android, or on iOS < 15.4 (according to MDN-untested).
Object.hasOwn was introduced into RN core in #46386 (CC @yungsters)
We either need to replace that usage, or add a shim/polyfill for Object.hasOwn.
IMO, this is stable release blocking for RN 0.77.
Steps to reproduce
react-native$ cd packages/rn-tester
rn-tester$ yarn install-android-jsc
rn-tester$ yarn start
Navigate to FlatList -> Basic.
React Native Version
0.77.0-rc.0
Affected Platforms
Runtime - Android
Output of npx react-native info
npx react-native info
info Fetching system and libraries information...
System:
OS: macOS 15.1.1
CPU: (10) arm64 Apple M1 Max
Memory: 145.30 MB / 64.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 22.6.0
path: ~/.nvm/versions/node/v22.6.0/bin/node
Yarn:
version: 1.22.19
path: ~/homebrew/bin/yarn
npm:
version: 10.8.2
path: ~/.nvm/versions/node/v22.6.0/bin/npm
Watchman:
version: 2024-11-25T03:04:25Z
path: /usr/local/bin/watchman
Managers:
CocoaPods:
version: 1.11.3
path: /Users/robhogan/homebrew/bin/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 24.0
- iOS 18.0
- macOS 15.0
- tvOS 18.0
- visionOS 2.0
- watchOS 11.0
Android SDK:
API Levels:
- "26"
- "27"
- "28"
- "29"
- "30"
- "31"
- "32"
- "33"
- "34"
- "35"
Build Tools:
- 34.0.0
- 35.0.0
System Images:
- android-34 | Google APIs ARM 64 v8a
- android-35 | Pre-Release 16 KB Page Size Google Play ARM 64 v8a
Android NDK: Not Found
IDEs:
Android Studio: 2024.1 AI-241.15989.150.2411.11948838
Xcode:
version: 16.0/16A242d
path: /usr/bin/xcodebuild
Languages:
Java:
version: 1.8.0_302
path: /usr/local/bin/javac
Ruby:
version: 2.7.6
path: /Users/robhogan/.rbenv/shims/ruby
npmPackages:
"@react-native-community/cli": Not Found
react:
installed: 18.3.1
wanted: 18.3.1
react-native: Not Found
react-native-macos: Not Found
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: Not found
newArchEnabled: Not found
iOS:
hermesEnabled: Not found
newArchEnabled: Not found
Stacktrace or Logs
Warning: TypeError: Object.hasOwn is not a function. (In 'Object.hasOwn(next, key)', 'Object.hasOwn' is undefined)
This error is located at:
in Animated(View) (created by TouchableOpacity)
in TouchableOpacity (created by TouchableOpacity)
in _c (created by RNTesterDocumentationURL)
in RNTesterDocumentationURL (created by HeaderAndroid)
in RCTView (created by View)
in View (created by HeaderAndroid)
in RCTView (created by View)
in View (created by HeaderAndroid)
in RCTView (created by View)
in View (created by HeaderAndroid)
in HeaderAndroid (created by RNTTitleBar)
in RNTTitleBar (created by RNTesterApp)
in RNTesterApp
in RCTView (created by View)
in View (created by AppContainer)
in RCTView (created by View)
in View (created by AppContainer)
in AppContainer
in RNTesterApp(RootComponent)
the version i updated is based on WebKitGTK 2.26.4, which is still old and would not support Object.hasOwn. there is a hard blocker for updating jsc-android to newer version. newer jsc doesn't have a way to turn off Intl support. we have to ship Intl variant only and would definitely increase apk size. that's why i plan to update jsc version and ship Intl variant only when we moving away jsc from core.
Description
Object.hasOwn
is not implemented in the version of JSC shipped with RN Android, or on iOS < 15.4 (according to MDN-untested).Object.hasOwn
was introduced into RN core in #46386 (CC @yungsters)We either need to replace that usage, or add a shim/polyfill for
Object.hasOwn
.IMO, this is stable release blocking for RN 0.77.
Steps to reproduce
Navigate to FlatList -> Basic.
React Native Version
0.77.0-rc.0
Affected Platforms
Runtime - Android
Output of
npx react-native info
Stacktrace or Logs
Reproducer
https://github.com/facebook/react-native
Screenshots and Videos
The text was updated successfully, but these errors were encountered: