Website: https://flatteredwithflutter.com/github-search-and-bloc/

We will cover briefly about

  1. Integrate Github API

  2. Define UI states 

  3. Create Search BLoC

  4. Update UI as per states

Integrate Github API

We define an abstract class (aka contract), which includes one method.

Github has a public endpoint exposed for searching the repositories, and we append the user-defined search term to it.

api.github.com/search/repositories?q='YOUR SEARCH TERM'

So now, we implement the abstract class in our GithubApi (our implementation class name).

class GithubApi implements GithubSearchContract

Medium: https://levelup.gitconnected.com/github-search-and-bloc-523d51848c68

Website: https://flatteredwithflutter.com/github-search-and-bloc/

DevTo: https://dev.to/aseemwangoo/github-search-and-bloc-3gpi