Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
private httpClient: HttpClient,
private transferState: TransferState,
private injector: Injector,
@Inject(PLATFORM_ID) private platformId: Object
) {
const req = isPlatformServer(this.platformId)
? this.injector.get('request')
: undefined;
const searchParameters = parseServerRequest(req);
this.instantsearchConfig = {
searchParameters,
indexName: 'instant_search',
urlSync: true,
searchClient: createSSRSearchClient({
makeStateKey,
HttpHeaders,
appId: 'latency',
apiKey: '6be0576ff61c053d5f9a3225e2a90f76',
transferState: this.transferState,
httpClient: this.httpClient,
}),
};
}
}