GifRepository class

GifRepository is a class that handles the fetching of gifs from the Giphy API.

It uses the Dio package for making HTTP requests.

Constructors

GifRepository({required Dio dio})

Properties

dio → Dio
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

fetchTrendingGif({required String apikey, required int offset, required String language}) Future<Either<String, GiphyGif>>
Fetches a trending gif from the Giphy API.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
searchGif({required String apikey, required int offset, required String keyword, required String language}) Future<Either<String, GiphyGif>>
Searches for a gif in the Giphy API.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited