Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52483
Changelog: [internal]
This is a small refinement for `performance.mark` and `performance.measure` to use `structuredClone` to copy the value of the `detail` field, instead of assigning it by reference.
This still doesn't completely fix the semantics of `performance.mark` and `performance.measure`, as the entries returned by those methods aren't referentially equal to the entries reported by `PerformanceObserver` (and the latter don't have the `detail` field yet).
Reviewed By: huntie
Differential Revision: D77863037
fbshipit-source-id: 54d959612ecd560250e49bb0887bb12112a0142f
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52476
Changelog: [Internal] - Refactor package structure on Android to prepare for experimental VirtualView so that non-view related objects go under `virtual` and the native view goes under `view`.
This breaks dependency circles for experimental VirtualView in upcoming change.
Reviewed By: yungsters
Differential Revision: D77335426
fbshipit-source-id: 3b978e9cc5ad376c71aebc039cfc74d2515d2cfa
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52470
These metrics are not actively consumed and are highly noisy.
Changelog: [Android][Removed] Deprecated MessageQueueThreadPerfStats API and replaced with stub.
Reviewed By: cortinico
Differential Revision: D77867087
fbshipit-source-id: 8bf7423ad60cb3bb21a5dbe94771d5a71832633d
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52399
I'm raising the deprecation warnings for those methods that are using legacy arch.
Previously the `DeprecatedInNewArchitecture` was not generating warnings for user in their builds, while now the Kotlin's/Java's `DeprecatedInNewArchitecture` it will.
Changelog:
[Android] [Changed] - Introduce more deprecation warnings for Legacy Arch classes
Reviewed By: mdvacca
Differential Revision: D77736713
fbshipit-source-id: bc21729ed8253d3ec6b6a40577bcd76622c3f8a6
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52442
Changelog: [Internal]
The sample is from an outdated approach of enabling C++ Modules in RN which is not recommended anymore.
Prefer C++ Turbo Modules if you need to expose / access C or C++ APIs in RN apps:
https://reactnative.dev/docs/the-new-architecture/pure-cxx-modules
It is not included in any RNTester app at this time
Reviewed By: cortinico
Differential Revision: D77771111
fbshipit-source-id: a4fe1d13fd0224babc46f54b921a036f7b237a48
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52401
changelog: [internal]
- Mark ShadowNode::ListOfWeak as deprecated with appropriate deprecation message
- Replace all usages of ShadowNode::ListOfWeak with std::vector<std::weak_ptr<const ShadowNode>>
- Updated primitives.h and ReactNativeCPP.api to use the explicit type instead of the alias
This change continues the effort to remove type aliases in favor of explicit standard library types for better code clarity and maintainability.
Reviewed By: christophpurrer
Differential Revision: D77652083
fbshipit-source-id: 79cad019e039c19f661346604ff49a44a4af7a79
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52465
Changelog: [internal]
Now that we have enough coverage for the Performance API in Fantom, Jest tests where most of the API is mocked are redundant and useless, so this removes them (and the mock).
Reviewed By: huntie
Differential Revision: D77860888
fbshipit-source-id: 7dbd1a8a43b056a3b34e4e37d578be9ccb521824
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52462
Changelog: [internal]
This adds a few more tests for `performance.getEntries`, `performance.getEntriesByName` and `performance.getEntriesByType`.
Reviewed By: huntie
Differential Revision: D77801746
fbshipit-source-id: 42f80c4e2b787c455b149ee38d071511181532b0
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52431
Changelog: [internal]
`performance.measure` supports passing mark names as `start` and `end` options, so this fixes the Flow type before fixing the actual implementation.
It also makes it so you can't specify both `end` and `duration`, enforced by the type system.
Reviewed By: huntie
Differential Revision: D77795991
fbshipit-source-id: e89f509c7efc2fa49d17d79bc19bc1d14e007871
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52432
Changelog: [internal]
This creates a battery of tests for `performance.mark` and `performance.measure`. For this, it was necessary to add a new method in the native module to mock the current time.
Many of the tests are currently failing, as the API doesn't support all the options or behaviors defined in the spec. They're skipped here and will be re-enabled and fixed in a following diff.
Reviewed By: huntie
Differential Revision: D77795989
fbshipit-source-id: 3ebf18c8ac336df1fb43003a55a4678b52e8982d
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52402
changelog: [internal]
Mark ShadowNode::ListOfShared as deprecated and replace most usages throughout the React Native renderer codebase with the explicit std::vector<std::shared_ptr<const ShadowNode>> type. This improves code clarity by making the container type explicit rather than relying on a type alias.
Reviewed By: christophpurrer
Differential Revision: D77651676
fbshipit-source-id: 8c4bd9b8cbbe467384b947ef9e7a4524f2053e36
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52412
Changelog: [Internal]
The sample is from an outdated approach of enabling C++ Modules in RN which is not recommended anymore.
Prefer C++ Turbo Modules if you need to expose / access C or C++ APIs in RN apps:
https://reactnative.dev/docs/the-new-architecture/pure-cxx-modules
It is not included in any RNTester app at this time
Reviewed By: cortinico
Differential Revision: D77770455
fbshipit-source-id: 987c9f2b9ab4145a2f6a724aad12d8473957dbe8
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52407
Changelog: [Internal]
The sample is from an outdated approach of enabling C++ Modules in RN which is not recommended anymore.
Prefer C++ Turbo Modules if you need to expose / access C or C++ APIs in RN apps:
https://reactnative.dev/docs/the-new-architecture/pure-cxx-modules
Reviewed By: javache
Differential Revision: D77765443
fbshipit-source-id: 112fef4c1a7e1c567f3c1d471728a1dfc926adc6
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52388
Changelog: [Internal]
Similar to `AsyncCallback<>` (the foundation of `AsyncPromise`) we should allow `void` Promise types in C++ such as `AsyncPromise<>`
Reviewed By: rbergerjr
Differential Revision: D77712020
fbshipit-source-id: d7360df5cc1b77f1e03e5fb73b0b468f6e3a415b
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52456
Remove the last use of a Metro deep import in preparation for making all deep imports semver-private.
Changelog: [Internal]
Reviewed By: huntie
Differential Revision: D77450110
fbshipit-source-id: de7aa9c1f6b0d281fe8a6c3bd95e721c5bb58c63
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52438
Motivation: After some investigation, these make sense as private APIs, and we intend to modify `UriHandler` slightly in order to report blob response body payloads via CDP for Network debugging.
Changelog:
[Android][Removed] - Internalize `NetworkingModule`'s `UriHandler`, `RequestBodyHandler`, and `ResponseHandler` APIs
Reviewed By: cortinico
Differential Revision: D77799144
fbshipit-source-id: 20c36f52a900830091a253ab9917832c30b31d31
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52436
Reordered the different property types in the switch/case to group similar outputs together.
Changelog: [Internal]
Reviewed By: christophpurrer
Differential Revision: D77799101
fbshipit-source-id: 5b7c6d188e9ffa0f1e41f44f82f438afeda04d74
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52439
Users should not be passing true/false values for the 3 params in the `load()` method. The app template already uses the no param overload.
I'm deprecating it so it can go in 0.81.
Changelog:
[Android] [Changed] - Deprecate the DefaultNewArchitectureEntryPoint.load(Boolean, Boolean, Boolean)
Reviewed By: rubennorte
Differential Revision: D77739268
fbshipit-source-id: c901d1ed2e9623b0fa39f4e2d79f25404c284b8d
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52427
Adds and wires up a minimal implementation of `PerformanceResourceTiming` on the JS side. This materialises D74245441 in user space.
When all feature flags are enabled, network requests can now be observed from JS via `PerformanceObserver`.
Changelog: [Internal]
Reviewed By: rubennorte
Differential Revision: D75062713
fbshipit-source-id: 06523e70f57feaaa53432ef21fa92676d1e90360