Giter Club home page Giter Club logo

johndev19 / drum-machine Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 10 KB

This project is a Drum Machine web application built as part of the FreeCodeCamp Front End Development Libraries certification. It allows users to play drum sounds by clicking on drum pads or using keyboard keys.

Home Page: https://johndev19.github.io/Drum-Machine/

License: MIT License

CSS 53.63% JavaScript 35.26% HTML 11.11%
codecampclub css drum-machine html react reactjs web-development

drum-machine's Introduction

Drum Machine

Project Overview

This project is a Drum Machine web application built as part of the FreeCodeCamp Front End Development Libraries certification. It allows users to play drum sounds by clicking on drum pads or using keyboard keys.

Features

  • Interactive drum pads that can be triggered by mouse clicks or keyboard presses
  • Visual feedback when drum pads are activated
  • Display showing the name of the currently played sound

Technologies Used

  • HTML5
  • CSS3
  • JavaScript (ES6+)
  • React.js
  • Create React App

User Stories Fulfilled

  1. The app has an outer container with id="drum-machine" that contains all other elements.
  2. Within #drum-machine, there is an element with id="display".
  3. Within #drum-machine, there are 9 clickable drum pad elements, each with:
    • A class name of "drum-pad"
    • A unique id describing the audio clip
    • Inner text corresponding to keyboard keys Q, W, E, A, S, D, Z, X, C
  4. Each .drum-pad contains an HTML5 audio element with:
    • A src attribute pointing to an audio clip
    • A class name of "clip"
    • An id corresponding to the inner text of its parent .drum-pad
  5. Clicking on a .drum-pad element triggers its audio clip.
  6. Pressing the trigger key associated with each .drum-pad triggers its audio clip.
  7. When a .drum-pad is triggered, a string describing the associated audio clip is displayed in the #display element.

Installation and Setup

  1. Clone the repository:
    git clone [https://github.com/JohnDev19/Drum-Machine]
    
  2. Navigate to the project directory:
    cd drum-machine
    
  3. Install dependencies:
    npm install
    
  4. Start the development server:
    npm start
    
  5. Open http://localhost:3000 to view it in the browser.

Usage

  • Click on the drum pads or press the corresponding keyboard keys to play sounds.
  • The name of the played sound will be displayed in the display area.

Contributing

Contributions, issues, and feature requests are welcome. Feel free to check issues page if you want to contribute.

License

This project is MIT licensed.

Acknowledgements

  • FreeCodeCamp for the project idea and requirements

drum-machine's People

Contributors

johndev19 avatar

Stargazers

 avatar

Watchers

 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.