chatwootRepositoryProvider top-level property

ProviderFamily<ChatwootRepository, RepositoryParameters> chatwootRepositoryProvider
final

Provides an instance of chatwoot repository

Implementation

final chatwootRepositoryProvider =
    Provider.family<ChatwootRepository, RepositoryParameters>(
        (ref, repoParams) {
  final localStorage = ref.read(localStorageProvider(repoParams.params));
  final clientService =
      ref.read(chatwootClientServiceProvider(repoParams.params));

  return ChatwootRepositoryImpl(
      clientService: clientService,
      localStorage: localStorage,
      streamCallbacks: repoParams.callbacks);
});