Skip to content

Bestbynature/leaderboard-project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

26 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation


Leaderboard.Project.-.12.April.2023.mp4

πŸ“— Table of Contents

πŸ“– [LeaderBoard Project]

LeaderBoard Project is a JavaScript project that builds the Leaderboard list app, using webpack and ES6 features (notably modules). It employs the Leaderboard API using JavaScript async and await, with some nice styling. The application contains two buttons - Refresh and Submit. Clicking the Submit button after filling the name and score input will perform a POST method on the API and bring back a confirmatory message in the DOM (which disappears after 5 seconds). In contrast, clicking the Refresh button performs a GET method and pulls the currently available data, with respect to the already programmed GameID, from the API and displays the full list in the DOM.

πŸ›  Built With

Tech Stack

Client
  • HTML
  • CSS
  • JAVASCRIPT

Key Features

  • [Linter checks]
  • [Webpack]
  • [API]

(back to top)

πŸš€ Live Demo

(back to top)

πŸ’» Getting Started

To get a local copy up and running, follow these steps.

(back to top)

Prerequisites

In order to run this project you need:

  • The current version of node
  • To have Git installed on your local machine
  • Node Package manager (npm)
  • An editor such as Visual Studio Code

(back to top)

Setup

Clone this repository to your desired folder:

  • Create your classic access token from github.com
  • run "git clone https://{access_token}@github.com/username/{repo_name}.git"
  • Update your git identity by running "git config --global user.email "your_email@gmail.com""
  • Update your name on git by running "git config --global user.name "your_name"

(back to top)

Install

Install this project with:

- In the first commit of your feature branch create a .github/workflows folder and add a copy of [.github/workflows/linters.yml](https://github.com/microverseinc/linters-config/blob/master/html-css-js/.github/workflows/linters.yml) to that folder.
- create a .gitignore file and add 'node_modules' to it
- run 'npm init -y'
- run 'npm install --save-dev hint@7.x'
- Copy [hintrc](https://github.com/microverseinc/linters-config/blob/master/html-css-js/.hintrc) to the root directory of your project.
- run 'npx hint .'
- Fix validation errors.
- run 'npm install --save-dev stylelint@13.x stylelint-scss@3.x stylelint-config-standard@21.x stylelint-csstree-validator@1.x'
- Copy [stylelintrc.json](https://github.com/microverseinc/linters-config/blob/master/html-css-js/.stylelintrc.json) to the root directory of your project.
- Run 'npx stylelint "\*_/_.{css,scss}"'
- fix linter errors
- run "npm install --save-dev eslint@7.x eslint-config-airbnb-base@14.x eslint-plugin-import@2.x babel-eslint@10.x"
- Copy [eslintrc.json](https://github.com/microverseinc/linters-config/tree/master/html-css-js)
- Run npx eslint . on the root of your directory of your project
- Fix linter error.

### To Install Jest
- run npm install --save-dev jest
- add " "test": "jest", "watch": "jest --watch *.js" to the scripts section of package.json"
- run npm install --save-dev @babel/plugin-transform-modules-commonjs
- create a file at the root called .babelrc
- copy `{
    "env": {
        "test": {
            "plugins": ["@babel/plugin-transform-modules-commonjs"]
        }
    }
}` inside the file

(back to top)

### Usage

To run the project, execute the following command:

  use git bash to open in Vs code
  use npm start to run web dev server
  npm run build to get the production version

(back to top)

Run tests

To run tests, run the following command:

Run "npx hint ."
Run "npx stylelint "**/*.{css,scss} --fix " to fix linters
Run "npx eslint . --fix to fix linters"

(back to top)

Deployment

You can deploy this project using:

  • github pages
- npm run deploy

(back to top)

πŸ‘₯ Authors

πŸ‘€ Author

(back to top)

πŸ”­ Future Features

  • [contact form page]
  • [A feature for prize inclusion]
  • [A feature for updating the scores on the board]

(back to top)

🀝 Contributing

Contributions, issues, and feature requests are welcome!

Feel free to check the issues page.

(back to top)

⭐️ Show your support

If you like this project, kindly drop a star for me.

(back to top)

πŸ™ Acknowledgments

I would like to use this medium to appreciate Microverse for giving me this type of opportunity.

(back to top)

πŸ“ License

This project is MIT licensed.

(back to top)

About

This JavaScript project builds the Leaderboard list app, using webpack and ES6 features, notably modules. It employs the Leaderboard API using JavaScript async and await, with some nice styling.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published