Skip to content

A simplistic implementation of a hacker news app using hacker news api

Notifications You must be signed in to change notification settings

adar2378/hacker_news

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hacker News

Hacker News is a very basic application with the following functionality

  • Shows top 25 stories
  • User can search stories
  • View the story in a webview along with the related comments and replies

Screenshots

Structure

  • All the blocs, screens, widgets shared by the application are placed in common folder
  • Inside modules folder for each module, Search and Top Stories, there are blocs, repositories, screens, models, adapters, widgets etc.
  • TextStyle, Color etc are stored in styles folder.

Basic API call flow

  • First we try to collect the story ids in a List
  • Then we fetch the details of the stories and wait for them to retrieve all the data
  • Since this is resource-heavy work, we put this in a separate isolate so that this work doesn't block our UI thread.
  • After fetching all the needed data, we change the data according to our need and feed it to the UI.

Running the code

  • run flutter pub get to get the needed package
  • run flutter run to run the application

P.S: Diagrams and screenshots can be found inside root/diagrams and root/screenshots folders repsectively.

About

A simplistic implementation of a hacker news app using hacker news api

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages