Summary:
This adds a new npm package "internaldocs-fb-helpers", and shows example usage in the flipper package.
This will stop everyone from having to inline the function definitions everywhere as is currently the case.
(It's using the old internaldocs name, to match the existing docusaurus-plugin-internaldocs-fb package - I don't think that's a big deal.)
It currently exports two methods:
* `fbContent(internalContent, publicContent)`
* Allows you to return internal or external content based on build variant.
* Has named args so you don't accidentally put internal stuff in the external arg.
* `isInternal(): boolean`
* Not strictly necessary, but helps if you want to write your docs using an boolean variable rather than a switching function every time.
* `fbInternalOnly(internalContent)`
* Convenience method for when you want internal content, or nothing.
I could have put these inside the existing docusaurus plugin, but that has docu v2 as a peer dependency, and I want these helpers to work on v1 as well, so made it a standalone package.
Reviewed By: passy
Differential Revision: D23474462
fbshipit-source-id: 22e5be6de2f3233deb298f1542a06e3575b6555a
Summary:
The function `setLayoutParams` expects the values to be set to be at array position 0+, and they were on position 1+ instead.
This effectively prevented users from setting LayoutParameters.
Reviewed By: muraziz
Differential Revision: D23538531
fbshipit-source-id: cc828363ee8d7408d1df29d98c37b09893826bb1
Summary: This diff uses the new picker defined in EnumMapping for regular Android View properties.
Reviewed By: muraziz
Differential Revision: D23538532
fbshipit-source-id: be5b776453e7322fb13a5f9e6a66a1f8d1243e79
Summary: This diff makes EnumMapping compatible with the new Layout widget "picker"
Reviewed By: muraziz
Differential Revision: D23538548
fbshipit-source-id: 7bdb01648c1ad5e2d0d7594c98df5ed89d893702
Summary: Detect if resolved path is properly computed and accordingly display a success or error notification within InAppErrorReporter.
Reviewed By: arpitratan
Differential Revision: D23425001
fbshipit-source-id: 4ca903a8b9e83dc0e11bb823537f56678dd85b76
Summary: This change removes the dependency of FlipperEditor from AndroidX, which prevents it from moving to the Litho repository
Reviewed By: Andrey-Mishanin
Differential Revision: D23475867
fbshipit-source-id: a330c676859ed9ce9a0ab186dd206310d2eccca5
Summary:
Bumps [react-native-flipper](https://github.com/facebook/flipper) from 0.53.0 to 0.54.0.
<details>
<summary>Commits</summary>
<ul>
<li><a href="36825675d1"><code>3682567</code></a> Flipper Release: v0.54.0</li>
<li><a href="96803821ec"><code>9680382</code></a> Bump babel/core from 7.10.4 to 7.11.4 in /react-native/ReactNativeFlipperExa...</li>
<li><a href="8309ebcdcf"><code>8309ebc</code></a> Bump metro-react-native-babel-preset from 0.58.0 to 0.63.0 in /react-native/R...</li>
<li><a href="b109fc4d3e"><code>b109fc4</code></a> FQN Cleanup</li>
<li><a href="47d3dd6413"><code>47d3dd6</code></a> Load routes to device during init (<a href="https://github-redirect.dependabot.com/facebook/flipper/issues/1491">https://github.com/facebook/flipper/issues/1491</a>)</li>
<li><a href="3e95645f45"><code>3e95645</code></a> Fix release builds on Android, take 2 (<a href="https://github-redirect.dependabot.com/facebook/flipper/issues/1329">https://github.com/facebook/flipper/issues/1329</a>)</li>
<li><a href="79b1f8a1c1"><code>79b1f8a</code></a> Tell FB employees to use MSC instead of downloading</li>
<li><a href="0b528f19ce"><code>0b528f1</code></a> Escape table names and keys</li>
<li><a href="39a465b8b8"><code>39a465b</code></a> Use idb to poll for devices, if it is installed</li>
<li><a href="573bf8a940"><code>573bf8a</code></a> Fix scoped symlink module resolution (<a href="https://github-redirect.dependabot.com/facebook/flipper/issues/1482">https://github.com/facebook/flipper/issues/1482</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/facebook/flipper/compare/v0.53.0...v0.54.0">compare view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/configuring-github-dependabot-security-updates)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/1507
Reviewed By: mweststrate
Differential Revision: D23473019
Pulled By: nikoant
fbshipit-source-id: d0ec59dfc2aa7ae0d041cd77132cf8c16be68060
Summary:
This is an automated PR to update the Podfile.lock.
- Make sure that the Podfile.lock contains latest FlipperKit and Flipper pod versions.
- Also make sure that all the dependencies are updated to the latest one.
- This is auto-generated by [create-pull-request](https://github.com/peter-evans/create-pull-request)
Pull Request resolved: https://github.com/facebook/flipper/pull/1511
Reviewed By: priteshrnandgaonkar
Differential Revision: D23473025
Pulled By: nikoant
fbshipit-source-id: 16b36f2d952f47186b261b27b0bf2cabaab6a0c7
Summary:
`this` is not defined for `connectPlugin` and `disconnectPlugin` because `Array.prototype.map` [replace `this` to `undefined` if not specified](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map):
> If a thisArg parameter is provided, it will be used as callback's this value. Otherwise, the value undefined will be used as its this value. The this value ultimately observable by callback is determined according to the usual rules for determining the this seen by a function.

## Changelog
flipper-js-client-sdk: Fix undefined this due to array map
Pull Request resolved: https://github.com/facebook/flipper/pull/1506
Test Plan: Tried creating custom client and connecting to websocket server
Reviewed By: mweststrate
Differential Revision: D23473033
Pulled By: nikoant
fbshipit-source-id: bbfd9117da8aa8c7b491e219f98d17ccea48c0fd
Summary:
This is a first stab at documenting the new core distribution mechanism.
There are definitely areas I just brush over that should be expanded further,
but hopefully the release process and testing steps at the end help to clarify
some of the issues we've seen recently.
Reviewed By: mweststrate
Differential Revision: D23453713
fbshipit-source-id: 9efcfca1fbdbf5606080510c3e80bd19b49caf10
Summary:
The default max body size for the OkHttpInterceptor that is reported to Flipper seems unreasonably small, as most images, graphql responses etc are bigger. Increased it to 1MB
Since the network plugin doesn't do any work if it is not explicitly enabled in Flipper, this should not lead to further performance regression / starvation.
Reviewed By: jknoxville
Differential Revision: D23375720
fbshipit-source-id: e901105209aec7108d61fc20295a149c5582f22d
Summary: In the attached task an IPv6 address ended up in the URL send from IG. Since that URL couldn't be parsed, it crashed the network plugin. This change makes sure the plugin doesn't crash on invalid urls.
Reviewed By: cekkaewnumchai
Differential Revision: D23344503
fbshipit-source-id: c7ac2068e407a764d59e632bef1be7c4239c8c8a
Summary:
Images in the network plugin are rarely displayed in the network plugin, as it tries to use the public url to preview it. However, that won't if the endpoint is behind authentication, idempotent, etc. This diff changes the behavior to instead send the network body to flipper and use that to preview.
Changelog: [Network] Fixed image preview
Reviewed By: jknoxville, passy
Differential Revision: D23370743
fbshipit-source-id: 0070e9e38c10a5761b9f7190467e26f01a7b2471
See D23051239
Since the crash reporter endpoint does not exist anymore, and no data was reported there, removing the corresponding code from Flipper as well.
This also fixes the last remaining startup warning as well :)
Reviewed By: priteshrnandgaonkar
Differential Revision: D23472612
fbshipit-source-id: 7ce9f6a0261cdfe197a7da9b28a86407299effec
Summary:
Related diff [CK]: D23243009
This diff adds support for a protocol for layout messages where the type is recursively encoded as:
```
{
kind: "type",
data: ???
}
```
The meat of the diff is on FlipperEditor.java, SetDataOperations.java and InspectorFlipperPlugin.java. The others are there just for a change on an interface.
We check if the message adheres to the new encoding, otherwise we fall back to the old behavior. If it's the new encoding, the message is traversed recursively flattening the types to EditorValue using the type hints provided.
Reviewed By: muraziz
Differential Revision: D23243009
fbshipit-source-id: 0f313455885930f3beaaadb66f3bf394f109ea23
Summary: Adds support in Flipper for the picker widget. The way it reaches Flipper is a bit nasty, using `toString` to produce a JSON value.
Reviewed By: passy
Differential Revision: D23294091
fbshipit-source-id: e3398e6fb474e46bdaac1960aeaf57e201946413
Summary: This diff adds analytics for events like uploading certs, zipping certs.Also logs the payload data received in trusted and untrusted request handlers. It will be helpful to debug the issues through this events.
Reviewed By: jknoxville
Differential Revision: D23374024
fbshipit-source-id: 6fa709bbf05e1b99ed1882be953abbd968eefc6e
Summary:
The first launch of Myles might produce a lag connected with the fact that Myles daemon needs to start (mainly, set up a Watchman subscription and depending on what state Watchman is in, it could take ~10 secs to initialise).
Therefore, trying to invoke Myles as soon as the Layout Plugin is enabled.
Reviewed By: mweststrate
Differential Revision: D23371702
fbshipit-source-id: 59ee3fb20b2df1330ff4048462f342ce2e12210a
Summary: This diff adds a new PoC widget for the Layout Editor to select a string from a picker. It takes a Set of values and uses them as representation. One of them is considered selected.
Reviewed By: muraziz
Differential Revision: D23374681
fbshipit-source-id: 324a3dd74a6b16edb77b862345d5288dd714fea1
Summary:
This fixes two issues. One issue where the recent change of cdn to lookaside hostname broke our build download process. More about this can be found [here](https://fb.workplace.com/groups/flipperfyi/permalink/772986153467682/).
It also fixes a bug which occurred on a retry when an error happened. Recently I made changes where, if the build is downloaded then retrying shouldn't redownload it. But we used to remove the downloaded builds after install phase, so this diff just removes the build when the download is successfull.
Reviewed By: nikoant
Differential Revision: D23372251
fbshipit-source-id: b57e69f65a20fc123191962d60165a62859d4ef7
Summary:
Related diff [Litho]: D23243009
This diff adds support for a protocol for layout messages where the type is recursively encoded as:
```
{
kind: "type",
data: ???
}
```
We check if the message adheres to the new encoding, otherwise we fall back to the old behavior. If it's the new encoding, the message is traversed recursively flattening the types to EditorValue using the type hints provided.
Reviewed By: Andrey-Mishanin
Differential Revision: D23319619
fbshipit-source-id: 79e8886f8f5a0aea4ec32938f1d5cd2fd645a297
Summary:
Just released a new version.
Pull Request resolved: https://github.com/facebook/flipper/pull/1428
Test Plan:
`./gradlew :android:installDebug`
However, I'm tethering right now and this is taking ages so I haven't
been able to complete this.
Reviewed By: mweststrate
Differential Revision: D23295098
Pulled By: passy
fbshipit-source-id: aa53fa1c47f0b02d2c8b9f12d66b1c600a37075b
Summary:
Adding a copy button next to search box. Copy nt or bloks raw bundle.
Before that we had a contxt menu on left side bar, which didn;t look good when we have only one active bundles (check appden comments in diff bellow)
Reviewed By: mweststrate
Differential Revision: D23345480
fbshipit-source-id: 919e7fec1d1884f5e8980c3b6cc5a94eb3d69be1
Summary:
This is an automated PR to update the Podfile.lock.
- Make sure that the Podfile.lock contains latest FlipperKit and Flipper pod versions.
- Also make sure that all the dependencies are updated to the latest one.
- This is auto-generated by [create-pull-request](https://github.com/peter-evans/create-pull-request)
Pull Request resolved: https://github.com/facebook/flipper/pull/1500
Reviewed By: jknoxville
Differential Revision: D23343573
Pulled By: mweststrate
fbshipit-source-id: 2193996ad1cb9983a64ce41851ee9ff4e49404d3
Summary: This diff fires a notification with a remediation suggestion when the client takes a long time to connect back, for both WW and FS_ACCESS case
Reviewed By: mweststrate
Differential Revision: D23321067
fbshipit-source-id: 17ab93974e9571a0ba78af05c624eeb0522637c6
Summary:
Flipper self inspection is being used by internal devs for a month now and peeple seems happy with it :) Let's make it available to open source devs!
changelog: Flipper Self inspection - Flipper Messages plugin added to dev builds to show messages sent/received from clients
Reviewed By: jknoxville
Differential Revision: D23345560
fbshipit-source-id: 95bac52b966a78fbfa8e4d4c4e15d9d45ca960f7
Summary: Now that the vanilla JS QuickPerformanceLoggerCore was created with the core methods from QPL, we are using this in Flipper so that we have one source of truth
Reviewed By: nubbel
Differential Revision: D23128231
fbshipit-source-id: 16841aab2563509c7184a09ecb8d3f534c53e896
Summary:
Bumps [react-native-flipper](https://github.com/facebook/flipper) from 0.51.0 to 0.53.0.
<details>
<summary>Commits</summary>
<ul>
<li><a href="f1c3bf8697"><code>f1c3bf8</code></a> Flipper Release: v0.53.0</li>
<li><a href="3c3d76be60"><code>3c3d76b</code></a> Send flipperstate to cert downloader</li>
<li><a href="2e98c7f3c7"><code>2e98c7f</code></a> Solve the bug where iOS physical device was not detected</li>
<li><a href="6170bfea41"><code>6170bfe</code></a> Upgrade fs-extra</li>
<li><a href="10b3c7db0b"><code>10b3c7d</code></a> Bump eslint-plugin-react-hooks from 4.0.4 to 4.1.0 in /flipper-js-client-sdk ...</li>
<li><a href="156b00ba42"><code>156b00b</code></a> Bump data-encoding from 2.2.0 to 2.3.0 in /packer (<a href="https://github-redirect.dependabot.com/facebook/flipper/issues/1449">https://github.com/facebook/flipper/issues/1449</a>)</li>
<li><a href="83227ff771"><code>83227ff</code></a> Bump jest from 26.2.2 to 26.3.0 in /react-native/ReactNativeFlipperExample (#...</li>
<li><a href="8aa29d00f2"><code>8aa29d0</code></a> Display Xcode for CK and Android Studio for Litho Components</li>
<li><a href="7d0dd3c656"><code>7d0dd3c</code></a> Implemented method to get CKComponent path</li>
<li><a href="41f1a0b454"><code>41f1a0b</code></a> Extra data send from iOS to Flipper Desktop</li>
<li>Additional commits viewable in <a href="https://github.com/facebook/flipper/compare/v0.51.0...v0.53.0">compare view</a></li>
</ul>
</details>
<br />
[](https://help.github.com/articles/configuring-automated-security-fixes)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/1496
Reviewed By: passy
Differential Revision: D23294300
Pulled By: mweststrate
fbshipit-source-id: b4a40dff10814ad3ae3d0947ca7c6bbdaf6f5207
Summary: With this change, I verified that our enterprise wilde app is able to connect to Flipper.
Reviewed By: jknoxville
Differential Revision: D23318335
fbshipit-source-id: cc952297ead1e8afcb1d9f5062e593e51e8ce893
Summary:
This diff improves showing details in the databases plugin in a few ways:
1. if there is large content, it is no longer rendered of screen
1. the section is now scrollable
1. made layout vertical rather than horizontal to have more space vor values
1. show the type of a value
1. better detection of JSON versus non-json values (primitives would be picked up as json, but in contrast binary ascii such as used in instagram wouldn't). This fixes also string to be rendered incorrectly by accidentally parsing them as numbers, such as can be seen in https://fb.workplace.com/groups/flippersupport/permalink/948112715669387/
Changelog: [Databases] Fixed several layout issues when inspecting rows, and added better JSON support and support for larger responses.
Reviewed By: cekkaewnumchai
Differential Revision: D23317689
fbshipit-source-id: 47ab5164e25da003e0d1a4ae7ccb1537b637e572
Summary: See linked task, data larger than 5KB would always be reported as blob. Increased this limit to 100KB, since if the user is looking at this data, it is proactively requested so it is fine if it is larger
Reviewed By: jknoxville
Differential Revision: D23317197
fbshipit-source-id: f563a980fa9567ac7e2f950b83c1888a7b295d77
Summary:
This is a replacement for PR https://github.com/facebook/flipper/pull/1486 which had the wrong username
When the network plugin is loaded, the route table in the device is empty. It needs to be populated with whatever routes have already been created and saved in local storage. Otherwise, the user would need to modify the routes to force an update.
Issue is described here - https://github.com/facebook/flipper/issues/1476
## Changelog
Routes updated in device when plugin is initialized
Pull Request resolved: https://github.com/facebook/flipper/pull/1491
Test Plan:
1. Create a mock for the get request in the sample Android app
2. Kill the app
3. Start the app
4. Issue the get request in the app
5. Verify that the request is mocked in the Network plugin

Reviewed By: passy
Differential Revision: D23292355
Pulled By: mweststrate
fbshipit-source-id: 2fe16e9067a627cae02a4b1db422952d364fd036
Summary:
Changelog: Fixed react-native-flipper causing Android release builds to fail
https://github.com/facebook/flipper/issues/1325 made progress but did not quite fix https://github.com/facebook/flipper/issues/1303. Android Release builds would still fail because `PackageList` depended on `FlipperPackage` and couldn't find it in release builds. There doesn't appear to be a clear way to set up a debug-only package with React Native's Android autolinking (see https://github.com/react-native-community/cli/issues/1211), so this change creates an empty `FlipperPackage` to satisfy that dependency, while still avoiding bundling the Flipper library into the release build.
(manual linking also works, but seems less-desirable for consumers of the library)
## Changelog
Add an empty `FlipperPackage` to the `release` folder to satisfy the reference put in `PackageList` by the autolinker for release builds.
Pull Request resolved: https://github.com/facebook/flipper/pull/1329
Test Plan:
Verified that release builds did fail without this change (using ReactNativeFlipperExample app)
Successfully built a React Native Android Release app from Android Studio using this library and verified that the APK still did not contain Flipper. Built debug and verified that Flipper still worked as before.
Reviewed By: passy
Differential Revision: D23292543
Pulled By: mweststrate
fbshipit-source-id: cb897a0e6dcdc04e29d676596447ca9dd68182c8