feat: add install readme et al

This commit is contained in:
Brooklyn Nicholson
2026-05-01 22:20:05 -05:00
parent 935970898f
commit 420f68e4e2
46 changed files with 3462 additions and 327 deletions
@@ -7,7 +7,9 @@ import type { RpcEvent } from '@/types/hermes'
interface GatewayBootOptions {
handleGatewayEvent: (event: RpcEvent) => void
onConnectionReady: (connection: Awaited<ReturnType<NonNullable<typeof window.hermesDesktop>['getConnection']>> | null) => void
onConnectionReady: (
connection: Awaited<ReturnType<NonNullable<typeof window.hermesDesktop>['getConnection']>> | null
) => void
onGatewayReady: (gateway: HermesGateway | null) => void
refreshHermesConfig: () => Promise<void>
refreshSessions: () => Promise<void>
@@ -87,11 +89,5 @@ export function useGatewayBoot({
onConnectionReady(null)
onGatewayReady(null)
}
}, [
handleGatewayEvent,
onConnectionReady,
onGatewayReady,
refreshHermesConfig,
refreshSessions
])
}, [handleGatewayEvent, onConnectionReady, onGatewayReady, refreshHermesConfig, refreshSessions])
}
@@ -1,15 +1,17 @@
import { useStore } from '@nanostores/react'
import { useCallback, useEffect, useRef } from 'react'
import { HermesGateway } from '@/hermes'
import type { HermesGateway } from '@/hermes'
import { $gatewayState, setConnection } from '@/store/session'
export function useGatewayRequest() {
const gatewayState = useStore($gatewayState)
const gatewayRef = useRef<HermesGateway | null>(null)
const connectionRef = useRef<Awaited<ReturnType<NonNullable<typeof window.hermesDesktop>['getConnection']>> | null>(
null
)
const gatewayStateRef = useRef(gatewayState)
const reconnectingRef = useRef<Promise<HermesGateway | null> | null>(null)