Summary: Changelog: [Layout] Addressed several performance issues in the layout plugin This diff and a few of the next stuff fix some performance issues in the Layout plugin. This diff fixes an issue where computing the context menu will cause all rows to render at all times, make the responiveness of the plugin quite slugish. The fix in this case is to build up the context menu lazily, and pass a stable ref to the function through the tree, rather than a new menu every time the root component renders. The changes in this diff and the next ones in total reduces the time (in prod builds) to draw a frame from ~200ms to ~5ms. Reviewed By: cekkaewnumchai Differential Revision: D27685983 fbshipit-source-id: a48b2ce2cdd1db31bb13122924617cbc3b6c198a
13 KiB
13 KiB