Commit Graph

3 Commits

Author SHA1 Message Date
John Knox
048cfe27d9 Fix update loop in PluginInstaller
Summary:
This is especially noticable on a slow internet connection.

If you type the search query quickly, it gets into a state update loop where:
* You type a character, it starts searching
* You type another character, it starts searching
* The first search finishes, updates the results and also updates the query
* This query change kicks off a new search...
* The second search finishes, updates the results... etc.

Fixed by never updating the query after searching. Instead, just discard search results if they come back after the component has changed. Use the cleanup feature of the effect hook for this.

Video of loop:
https://our.intern.facebook.com/intern/px/p/13Qc5

Reviewed By: mweststrate

Differential Revision: D20510360

fbshipit-source-id: 69ca39368fcfefc37b8f7251e059695ae738ddc0
2020-03-18 06:36:54 -07:00
John Knox
85abad2daf Strip flipper-plugin prefix when listing public plugins
Summary:
Stripping the common prefix when displaying plugin names.
Prior art for this is Jest, Babel, and ESlint.

Only altering it at the presentation level so we still work with the full name under the hood everywhere.

Reviewed By: mweststrate

Differential Revision: D20509786

fbshipit-source-id: ec6b3b064cdaa4d8dd32324fc19131c0bacd5c73
2020-03-18 06:36:54 -07:00
Anton Nikolaev
85c13bb1f3 Move desktop-related code to "desktop" subfolder (#872)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/872
Move all the JS code related to desktop app to "desktop" subfolder.

The structure of "desktop" folder:
- `src` - JS code of Flipper desktop app executing in Electron Renderer (Chrome) process. This folder also contains all the Flipper plugins in subfolder "src/plugins".
- `static` - JS code of Flipper desktop app bootstrapping executing in Electron Main (Node.js) process
- `pkg` - Flipper packaging lib and CLI tool
- `doctor` - Flipper diagnostics lib and CLI tool
- `scripts` - Build scripts for Flipper desktop app
- `headless` - Headless version of Flipper app
- `headless-tests` - Integration tests running agains Flipper headless version

Reviewed By: passy

Differential Revision: D20249304

fbshipit-source-id: 9a51c63b51b92b758a02fc8ebf7d3d116770efe9
2020-03-14 14:35:17 -07:00