GithubHelp home page GithubHelp logo

isd-sgcu / johnjud-frontend Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 56.76 MB

Frontend service for Johnjud project

Home Page: https://dev-johnjud.vercel.app/

JavaScript 0.43% HTML 0.92% CSS 0.19% TypeScript 98.37% Dockerfile 0.09%

johnjud-frontend's Introduction

JohnJohn

Web Application for JohnJud's website. This project is a part of johnjud_care.

Prerequisites

Please install the following.

This project use React as UI Library with Vite as development environment, and TailwindCSS as CSS Framework.

For front-end design you can see in JohnJud's Figma. You can download all resources in figma too.

For requirement Johnjud's Doc is here.

Getting Started

  1. Clone this repository
# Using SSH (recommended)
git clone [email protected]:isd-sgcu/johnjud-frontend.git

# Using Https (not recommended)
https://github.com/isd-sgcu/johnjud-frontend.git
  1. Go to project folder
cd johnjud-frontend
  1. Install all dependencies
pnpm install
  1. Run
pnpm dev
  1. Go to http://localhost:5173 in your fav browser.

Contributing

We will seperate a branch for each features and each person then, create pull request for combine code together.

  1. Go to dev branch and pull updated code
git checkout dev

git pull
  1. Create branch and go to your branch
git branch {your_branch_name}

git checkout {your_branch_name}

Note : exmaple of {your_branch_name} is boom/feat/pet-card, aungpao/refactor/main-page

  1. Push your branch upstream
git push --set-upstream origin {your_branch_name}
  1. Working with your code

  2. Stage and commit your changes

git add .

git commit -m {commit_message}
  1. Push your code in to your branch
git push
  1. Create pull request to dev branch in github
  2. Wait for the code to be reviewed and merged

Conventional Commit Format

In short, the commit message should look like this:

git commit -m "feat: <what-you-did>"

# or

git commit -m "fix: <what-you-fixed>"

# or

git commit -m "refactor: <what-you-refactored>"

The commit message should start with one of the following types:

  • feat: A new feature
  • fix: A bug fix
  • refactor: A code change that neither fixes a bug nor adds a feature
  • style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)

For more information, please read the conventional commit format documentation.

Implement API

This project use @tanstack/react-query with axios for fetching data and We will use custom queries hooks for query.

Please see in Discord for .env file

Structure

  • src/api : Store api fetching function using axios
  • src/types : Store type of fetched data
  • src/hook/queries : Store query function from @tanstack/react-query
  • src/hook/mutation : Store mutation function

Instruction Step :

  1. Create type from data in src/types if have pagination use Meta from src/types/common.ts
  2. Create fetching function in src/api and passing type to axios function
  3. Create query function in src/hook/quries or mutation function in src/hook/mutation
  4. Implement Query or Mutation function in Page and pass data to components

** Do not query data in any Component !!

johnjud-frontend's People

Contributors

punchanabu avatar thanaphomh avatar boomchanotai avatar kchanatipz avatar chanatpakornd avatar michaelscodaeng avatar teegoood avatar imsozrious avatar bookpanda avatar dependabot[bot] avatar

Stargazers

Tony avatar

Watchers

 avatar  avatar

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.