Giter VIP home page Giter VIP logo

hn-clone's People

Contributors

sphars avatar

Watchers

 avatar

hn-clone's Issues

Remember navigation selection when moving away from homepage

Currently, on load of the page, it fires getStories(TOPSTORIES) and only loads the top endpoint. If a user browses to another navigation (e.g. Ask) and navigates away in the same tab and goes back in their browser, it'll default to Top. I think a cookie to store last navigation may help or changing behavior of getStories(), or using query strings.

Add button to scroll to top

On long comment threads and story lists, this would allow a user to scroll quickly to the top. Could also extend it to scroll to the top level comment in current comment thread.

Add ability to load more stories

Right now, only the first 50 stories are loaded per fetch. This is an arbitrary limit. I believe the API will load a max of 500, so ability to load the next 50 or so stories would help. Either by fetching all 500 and showing only 50, or fetch the next 50 and show them. May depend on the API.

Serious refactoring/cleanup needed

Everything is sorta hacked together. Fetching a story and comment are essentially the same thing to the API, but the code in the app is nearly identical yet in separate functions. Needs cleanup for sure.

Move comments to new page

Comments on a story should be moved to new pages, rather than in-line with story lists. Should help with navigation issues.

Add dark theme

Everyone loves a good dark theme. Seems to be the latest rage.

Add ability to save stories

Story ids could be saved somewhere (local storage for now) and then saved stories and story comment thread could be saved for later.

Indicate the OP in comment replies

If the submitter of a story replies to their own story, comments written by them should have an indication that they were written by them (like how Reddit does it).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.