Summary:
This pre-suppresses the 154 error diff ahead of its release, since it is large.
Changelog: [Internal]
Reviewed By: samwgoldman
Differential Revision: D29065246
fbshipit-source-id: f418041305a46df410dcbe3d9a4db81a61ac7014
Summary:
This pre-suppresses the 153 error diff ahead of its release, since it is large.
Changelog: [Internal]
Reviewed By: mroch
Differential Revision: D28754374
fbshipit-source-id: 1806f53bc7d804644d434583a2dcd6da63d00328
Summary:
Some components are using `LogBoxData` directly, forcing logs to be shown on the screen even when LogBox is uninstalled. This changes all accesses to `LogBoxData` to go through `LogBox` so `uninstall` is used correctly.
It also changes when LogBox is installed, moving it from `AppContainer` to `InitializeCore` (which happens earlier) so we can capture more logs in LogBox.
Changelog: [General][Changed] Initialized LogBox earlier and centralized access in LogBox module
Reviewed By: rickhanlonii
Differential Revision: D27999361
fbshipit-source-id: 1115ef6b71e08cc33743d205da0064fbe9a74a0e
Summary:
This diff replaces YellowBox with YellowBoxDeprecated, adding warnings for using the module directly instead of YellowBox. Also adds a no-op message for unstable_enableLogBox.
Changelog: [Internal]
Reviewed By: motiz88
Differential Revision: D19949700
fbshipit-source-id: 269c341a2cedcdb2f7a80947d3239db078238201
Summary:
Migrates internal calls from ignoreWarnings to ignoreLogs so we can remove YellowBox.
Changelog: [Internal]
Reviewed By: TheSavior
Differential Revision: D19813781
fbshipit-source-id: 16c7b3f2cd38cba1901eccb4d5b9a2396a37ba1b
Summary:
This diff fixes two issues with LogBox in OSS.
Changelog: [Internal]
Reviewed By: mmmulani
Differential Revision: D19165696
fbshipit-source-id: 4dd9c480ea3d2b205f8e65cb32203949b1e32e8a
Summary:
This diff backports warning filter handling to yellow box. I also backported the skipped warning handling so that ignored patterns do not log to the console, same as LogBox.
Changelog: [Internal]
Reviewed By: gaearon
Differential Revision: D18573288
fbshipit-source-id: 5bf8e86f754adc808313d7ed02f98daaf65de98c
Summary:
This diff adds a new `unstable_enableLogBox` function to opt-into the new LogBox experience. If LogBox is not enabled early enough, we show an error with instructions.
With this, LogBox can be enabled with:
```
require('react-native').unstable_enableLogBox();
```
Changelog: [General] [Adds] unstable_enableLogBox
Reviewed By: zackargyle, rubennorte
Differential Revision: D18808940
fbshipit-source-id: 4b0234ddc4d1646515bf63110d5b02133780512e
Summary:
We are rolling out exact-by-default syntax to xplat/js.
I had to manually move around some comments to preserve proper placement.
Changelog: [Internal]
Reviewed By: jbrown215
Differential Revision: D18633611
fbshipit-source-id: 48f7468dcc55b1d00985419d035a61c6820b3abe
Summary:
This diff changes the LogBox to show the code frame for the first non-collapsed stack frame. Let me know what you think about this change!
Changelog: [Internal] LogBox changes
Reviewed By: rickhanlonii
Differential Revision: D18372456
fbshipit-source-id: ddf6d6c53ab28d11d8355f4cb1cb071a00a7366e
Summary: Removes the use of `framesToPop` to manage frame skipping in YellowBox and replaces it with support for the `collapse` field populated by Metro's [`customizeFrame`](https://github.com/facebook/metro/pull/435) config option. `framesToPop` is a deprecated mechanism which will be removed in the future.
Reviewed By: bvaughn
Differential Revision: D17857057
fbshipit-source-id: 120383ba4aad877b7ca79c7cf9d5b7579a490577
Summary:
This Diff is being posted for discussion purposes. It will not be ready to land until React DevTools v4 has been published to NPM.
Update React Native to be compatible with the [new version 4 React DevTools extension](https://github.com/bvaughn/react-devtools-experimental).
**Note that this is a breaking change**, as the version 3 and version 4 backends are **not compatible**. Once this update ships (in React Native) users will be required to update their version of the [`react-devtools` NPM package](https://www.npmjs.com/package/react-devtools). The same will be true for IDEs like Nuclide as well as other developer tools like Flipper and [React Native Debugger](https://github.com/jhen0409/react-native-debugger).
Related changes also included in this diff are:
* Pass an explicit whitelist of style props for the React Native style editor (to improve developer experience when adding new styles).
* Update `YellowBox` console patching to coordinate with DevTools own console patching.
* Also improved formatting slightly by not calling `stringifySafe` for strings (since this adds visible quotation marks).
Regarding the console patching- component stacks will be appended by default when there's no DevTools frontend open. The frontend will provide an option to turn this behavior off though:
{F168852162}
React DevTools will detect if the new version is used with an older version of React Native, and offer inline upgrade instructions:
{F169306863}
**Note that the change to the `RCTEnableTurboModule` will not be included in this Diff**. I've just turned those off temporarily so I can use v8+Chrome for debugging.
Reviewed By: rickhanlonii
Differential Revision: D15973709
fbshipit-source-id: bb9d83fc829af4693e7a10a622acc95a411a48e4
Summary:
Need to add explicit type annotations in these areas to unblock types-first architecture for Flow. These are locations the codemod could not automatically handle.
I'll call out areas I need a close eye on in the comments.
Reviewed By: panagosg7
Differential Revision: D16659053
fbshipit-source-id: 167dd2abe093019b128676426374c1c62cf71e7f
Summary: `parseErrorStack` (which uses the `stacktrace-parser` package) can return null file names, line numbers and column numbers. This diff updates the associated types and adds explicit null checks in some call sites.
Reviewed By: rickhanlonii
Differential Revision: D16542176
fbshipit-source-id: b72c73c05b95df0bbcb5b5baa7bc2d42cff1e074
Summary:
The previous comparison does not make sense (accessing props by index) - and always returns true. I'm going to assume there was a reason for implementing `shouldComponentUpdate` - although personally I'd just go for PureComponent (even if it may not be 100% accurate). Let me know if PureComponent sounds better.
## Changelog
not needed
Pull Request resolved: https://github.com/facebook/react-native/pull/25097
Differential Revision: D15575079
Pulled By: cpojer
fbshipit-source-id: 49aeb9d2997d3c613fe7a1af4534dff1607d53b4
Summary:
This is the next step in moving RN towards standard path-based requires. All the requires in `Libraries` have been rewritten to use relative requires with a few exceptions, namely, `vendor` and `Renderer/oss` since those need to be changed upstream. This commit uses relative requires instead of `react-native/...` so that if Facebook were to stop syncing out certain folders and therefore remove code from the react-native package, internal code at Facebook would not need to change.
See the umbrella issue at https://github.com/facebook/react-native/issues/24316 for more detail.
[General] [Changed] - Migrate "Libraries" from Haste to standard path-based requires
Pull Request resolved: https://github.com/facebook/react-native/pull/24749
Differential Revision: D15258017
Pulled By: cpojer
fbshipit-source-id: a1f480ea36c05c659b6f37c8f02f6f9216d5a323
Summary:
@public
This bumps Prettier to v1.16.4
Only format source files were updated.
Reviewed By: mjesun
Differential Revision: D14454893
fbshipit-source-id: 72f9872fe764a79dbf0d9fab9bebb1456b039f2f
Summary: To satisfy Flow, we want to account for RegExp as a valid ignore pattern.
Reviewed By: TheSavior
Differential Revision: D14303072
fbshipit-source-id: 4988fff5c6c6a12da99027e47216cedcf5a4db5a
Summary: We want to use a Regex for potentially more complicated string warnings. This will allow ignoring dynamic rules that include ID fields for example.
Differential Revision: D14079118
fbshipit-source-id: aff01c6b6eedc77cd91638988700c093dcda0488
Summary:
Adds the displayName prop to `View` and `Text` components. Because these now use `React.forwardRef`, they were showing as `Component` instead of their actual names.
Thanks to ljharb for helping to pinpoint the source of the issue!
Fixes#21937
Pull Request resolved: https://github.com/facebook/react-native/pull/21950
Differential Revision: D12827060
Pulled By: TheSavior
fbshipit-source-id: d812cae14d53ad821ab5873e737db63ad1a989e3
Summary: When symbolication fails, allow retrying without having to reload the current JS VM.
Reviewed By: ejanzer
Differential Revision: D9760666
fbshipit-source-id: 63837c81fe77a9b0b897a858e3d64bc7dcf2c3bd
Summary: Changes YellowBox to use feather icons for the left and right navigation so that we are not dependent on the system's (sometimes funky) unicode icons.
Reviewed By: ejanzer
Differential Revision: D9759134
fbshipit-source-id: b957c24afdccc04bfe78ae4750777c387c2acef4
Summary: This change drops the year from the copyright headers and the LICENSE file.
Reviewed By: yungsters
Differential Revision: D9727774
fbshipit-source-id: df4fc1e4390733fe774b1a160dd41b4a3d83302a
Summary:
ag -L --ignore __snapshots__ 'flow strict|noflow|generated|The controller you requested could not be found.' | ag '\.js$' | xargs ag -l 'flow' | sort > ~/temp
cat ~/temp | xargs ag -L 'flow strict' | xargs sed -i '' 's/flow$/flow strict-local/'
until flow check; do flow check --json | jq -r '.errors[].message[0].path' | sort | uniq | xargs hg revert; done
allow_many_files
The controller you requested could not be found.
The controller you requested could not be found.
Reviewed By: TheSavior
Differential Revision: D9004573
fbshipit-source-id: 936bd5741706b781be06bf08b6ad805a69407dfd
Summary:
Fixes an off-by-one bug that was causing trailing single characters to be truncated from YellowBox.
This snuck in during the revamp of YellowBox. Whoops!
@public
Reviewed By: TheSavior
Differential Revision: D8607388
fbshipit-source-id: d0efac4dec361456ef58347a60eb1486a888624a
Summary: This makes it so that `YellowBox` and its dependencies are completely stripped from production bundles.
Reviewed By: sahrens
Differential Revision: D8402545
fbshipit-source-id: 6993521280a02dfe5eab8863d12c46781f35444f
Summary: Uses `SafeAreaView` in the YellowBox inspector header so that it does not collide with the status bar.
Reviewed By: sahrens
Differential Revision: D8374861
fbshipit-source-id: e67358ac9268db8291cacf79df402f3bd5a2173d
Summary:
Replaces the existing `YellowBox` with a modern one.
Here are the notable changes:
- Sort warnings by recency (with most recent on top).
- Group warnings by format string if present.
- Present stack traces similar to RedBox.
- Show status of loading source maps.
- Support inspecting each occurrence of a warning.
- Fixed a bunch of edge cases and race conditions.
Reviewed By: TheSavior
Differential Revision: D8345180
fbshipit-source-id: b9e10d526b262c3985bbea639ba2ea0e7cad5081