An open API service indexing awesome lists of open source software.

https://github.com/xander1936/tip-calculator

This is a JavaScript App from the Clever Programmer path By Qazi that's calculating bill between persons.
https://github.com/xander1936/tip-calculator

anonymous-functions arrow-functions css dom dom-manipulation functions html javascript jsx template-literals

Last synced: 4 months ago
JSON representation

This is a JavaScript App from the Clever Programmer path By Qazi that's calculating bill between persons.

Awesome Lists containing this project

README

          

# tip-calculator
This is JavaScript App from the Clever Programmer By Qazi that's calcualating bill between persons.
/*
🌟 APP: Tip Calculator

These are the 3 functions you must use 👇
=========================================
calculateBill()
increasePeople()
decreasePeople()

These functions are hard coded in the HTML. So, you can't change their names.

These are all the DIV ID's you're gonna need access to 👇
========================================================
#1 ID 👉 'billTotalInput' = User input for bill total
#2 ID 👉 'tipInput' = User input for tip
#3 ID 👉 'numberOfPeople' = Current number of people you're splitting the bill between
#4 ID 👉 'perPersonTotal' = Total dollar value owed per person
*/

// Get global access to all inputs / The divs here (you'll need them later 😘)
// bill input, tip input, number of people div, and per person total div

// numberOfPeople variable gets number of people from number of people div; captures the string from the user input
// and turns it into a number with the JavaScript Number() method

// **The calculateBill() arrow function Calculates the total bill per person **

// **The increasePeople() arrow function incrases the number of the persons thats have to pay the bill. **

// **The decreasePeople() arrow function decrases the number of the persons thats have to pay the bill. **