Documentation
    Preparing search index...

    Type Alias MockMeshService

    MockMeshService: MockService<MockMeshState> & {
        inject(
            fromName: string,
            template: { content: string; kind: number; tags?: string[][] },
        ): NostrEvent | undefined;
        setOnline(online: boolean): void;
    }

    Mock mesh extension with circle controls.

    Type Declaration

    • inject: function
      • A member's event arrives at this device; returns the signed event, or undefined for a non-member.

        Parameters

        • fromName: string
        • template: { content: string; kind: number; tags?: string[][] }

        Returns NostrEvent | undefined

    • setOnline: function
    const mesh = createMockMeshService();
    mesh.inject('bob', { kind: 1, content: 'hello from bob' });