GithubHelp home page GithubHelp logo

whitedg / nextjs-hackernews Goto Github PK

View Code? Open in Web Editor NEW
4.0 2.0 1.0 7.02 MB

A HackerNews clone built with Next.js and shadcn/ui.

Home Page: https://nextjs-hackernews-omega.vercel.app

License: MIT License

TypeScript 98.14% CSS 1.16% JavaScript 0.70%
hackernews nextjs14 react-server-components server-actions shadcn-ui tailwindcss

nextjs-hackernews's Introduction

Next.js HackerNews

This is a HackerNews clone built with Next.js and shadcn/ui.

index

Live Demo

Features

  • Next.js App Router
  • React Server Components (RSCs) and Suspense
  • Server Actions for mutations
  • Beautifully designed components from shadcn/ui
  • Styling with Tailwind CSS
  • Browse stories: Top, Newest, Best, Show, Ask, Jobs.
  • Search for stories.
  • User authentication: Create an account or log in using your Hacker News account to access personalized features.
  • Mark stories as favorite.
  • Upvote stories or comments.
  • Add comments.
  • View user profile: About, Submitted, Comments, Favorites, Upvoted(private).
  • Responsive design: Friendly to both mobile and desktop.
  • Automatic light/dark mode based on system settings.

Screenshots

Desktop

index-desktop

story-desktop

about-desktop

upvoted-desktop

comments-desktop

login-desktop

Mobile

index-mobile story-mobile

about-mobile upvoted-mobile

comments-mobile login-mobile

Running Locally

Requires Node.js 18.17 or later.

  1. Clone the project.
git clone https://github.com/WhiteDG/nextjs-hackernews.git

cd nextjs-hackernews
  1. Install dependencies.
pnpm install
  1. Copy .env.example to .env.local and update the variables.
cp .env.example .env.local
  1. Run the development server with hot reload.
pnpm dev
  1. Open http://localhost:3000 with your browser to see the result.

  2. Build for production

pnpm run build
  1. Serve in production mode
pnpm start

APIs

This project leverages the power of various APIs to provide an enriched user experience:

License

Licensed under the MIT license.

nextjs-hackernews's People

Contributors

whitedg avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

kanakaraju043

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.