Skip to content

dsmontecastro/Sungka-Online

Repository files navigation

Sungka Online

Try it out: https://dsmontecastro.github.io/Sungka-Online/

A full-stack, monorepo project made primarily with React, Typescript, & Socket.io.

  • The front-end (client) is built on Vite, Tailwind CSS, and React-Redux.
  • The back-end (server) uses HTTP & ExpressJS, hosted on Adaptable.io.

Screenshot

Local Setup

  • Install Node & NPM, if needed.

  • Clone the repository.

    git clone https://github.com/dsmontecastro/Sungka-Online.git
  • Run these commands in the root directory.

    npm install
    npm run build
  • Make new .env files for both client and server:

    • Server
      HOST = 'localhost'    # or '127.0.0.1'
      PORT = 4000           # or any usable port
    • Client
      VITE_TITLE = 'Sungka Online'
      HOST = 'localhost'    # must match Server.HOST above
      PORT = 4000           # must match Server.PORT above
  • On two separate terminals, run these commands in order: sh npm run start -w ./packages/server sh npm run start -w ./packages/client

  • After use, clean up the files if necessary.

    npm run clean # deletes internal build & node_modules folders
    npm run reset # deletes the root node_modules folder