Returns a function for getting a generator that fetches people from the given data context.

Error if a data context is not provided

  • Parameters

    Returns ((personType: Readonly<{
        contactType: string;
    }>) => AsyncGenerator<Person, null, unknown>)

    a function for getting a generator that fetches people

      • (personType): AsyncGenerator<Person, null, unknown>
      • Returns a generator for fetching all people with the given type

        Parameters

        • personType: Readonly<{
              contactType: string;
          }>

          the type of people to return

        Returns AsyncGenerator<Person, null, unknown>

        a generator for fetching all people with the given type

        Error if no type is provided or if the type is not for a person