diff --git a/desktop/app/src/init.tsx b/desktop/app/src/init.tsx index 002ba5027..dbd76b8e0 100644 --- a/desktop/app/src/init.tsx +++ b/desktop/app/src/init.tsx @@ -75,7 +75,13 @@ async function getKeytarModule(staticPath: string): Promise { async function getExternalServer(path: string) { const options = { - WebSocket: WS, + WebSocket: class WSWithUnixDomainSocketSupport extends WS { + constructor(url: string, protocols: string | string[]) { + // Flipper exports could be large, and we snd them over the wire + // Setting this limit fairly high (1GB) to allow any reasonable Flipper export to be loaded + super(url, protocols, {maxPayload: 1024 * 1024 * 1024}); + } + }, }; const socket = new ReconnectingWebSocket(`ws+unix://${path}`, [], options); const server = await createFlipperServerWithSocket(