@dxos/halo-react
    Preparing search index...

    @dxos/halo-react

    @dxos/halo-react

    React hooks for the @dxos/halo services — the reactive, hook-based consumer surface that mirrors @dxos/react-client's HALO/space hooks but is backed by the HALO Effect services instead of @dxos/client directly.

    Provide the services once via HaloProvider, then use the hooks anywhere below it. See ../halo/CONSUMER_MIGRATION.md for the hook-by-hook migration guide.

    import { Context } from 'effect';
    import { Identity, Space } from '@dxos/halo';
    import { makeIdentityService, makeSpaceService } from '@dxos/halo-adapter-client';
    import { HaloProvider, useIdentity, useSpaces } from '@dxos/halo-react';

    const services = Context.empty().pipe(
    Context.add(Identity.Service, makeIdentityService(client)),
    Context.add(Space.Service, makeSpaceService(client)),
    );

    const App = () => (
    <HaloProvider services={services}>
    <Main />
    </HaloProvider>
    );

    const Main = () => {
    const identity = useIdentity();
    const spaces = useSpaces();
    // ...
    };

    Your ideas, issues, and code are most welcome. Please take a look at our community code of conduct, the issue guide, and the PR contribution guide.

    License: FSL-1.1-Apache-2.0 Copyright 2026 © DXOS