Skip to content

Commit

Permalink
chore(ts): simplify WithoutCredentials (#990)
Browse files Browse the repository at this point in the history
  • Loading branch information
Haroenv committed Feb 5, 2020
1 parent 850a7df commit d862a91
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions packages/algoliasearch/src/types/AlgoliaSearchOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,7 @@ import { ClientTransporterOptions } from '@algolia/client-common';
import { RecommendationClientOptions } from '@algolia/client-recommendation';
import { SearchClientOptions } from '@algolia/client-search';

export type WithoutCredentials<TClient> = Pick<
TClient,
Exclude<keyof TClient, 'appId'> & Exclude<keyof TClient, 'apiKey'>
>;
export type WithoutCredentials<TClient> = Omit<TClient, 'appId' | 'apiKey'>;

export type AlgoliaSearchOptions = Partial<ClientTransporterOptions> &
WithoutCredentials<SearchClientOptions>;
Expand Down

0 comments on commit d862a91

Please sign in to comment.