GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com โ€” GitHub - Ayinde225/loan-amortization-visualizer: Interactive loan amortization & mortgage schedule visualizer โ€” monthly payment, total interest, payoff date, balance chart, and prepayment savings. Built with React + Vite, amortization math from first principles and unit-tested.

BranchesTags
Open more actions menu

Latest commit

 

History

4 Commits
4 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
src
src
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
index.html
index.html
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
vite.config.js
vite.config.js
 
 

Repository files navigation

๐Ÿ’ฐ Loan Amortization & Mortgage Visualizer

๐Ÿ”— Live demo: https://ayinde225.github.io/loan-amortization-visualizer/

Deploy to GitHub Pages

An interactive tool for understanding the true cost of borrowing. Enter a loan amount, interest rate, and term, and instantly see your monthly payment, total interest, payoff date, a balance-over-time chart, and a full period-by-period amortization schedule โ€” plus how extra monthly payments shorten the term and save on interest.

Built with React + Vite. The amortization math is written from first principles (no finance library) and is fully unit-tested.

โœจ Features

  • Monthly payment from the standard amortization formula
  • Total interest / total paid / payoff date at a glance
  • Principal-vs-interest breakdown bar
  • Balance-over-time chart โ€” hand-drawn SVG, no chart library
  • Full amortization schedule, grouped by year and expandable
  • Prepayment analysis โ€” quantifies interest and time saved from extra payments
  • Responsive layout, keyboard-accessible inputs

๐Ÿงฎ The math

The fixed monthly payment for a fully-amortizing loan:

        P ยท r ยท (1 + r)^n
M =  โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
          (1 + r)^n โˆ’ 1

where P = principal, r = monthly interest rate (annual รท 12), and n = number of payments (years ร— 12). Each period, interest accrues on the outstanding balance and the remainder of the payment reduces principal. See src/lib/amortization.js.

๐Ÿš€ Getting started

npm install
npm run dev      # start the dev server
npm run build    # production build
npm test         # run the unit tests

๐Ÿ—‚๏ธ Project structure

src/
  lib/
    amortization.js       # pure finance math (payment, schedule, savings)
    amortization.test.js  # unit tests (Vitest)
    format.js             # currency / date formatting helpers
  components/
    LoanForm.jsx          # controlled inputs
    Summary.jsx           # KPI cards + breakdown + savings callout
    BalanceChart.jsx      # custom SVG balance-over-time chart
    ScheduleTable.jsx     # expandable year-by-year schedule
  App.jsx                 # composition + single source of truth for state

๐Ÿงช Testing

Amortization logic is covered by unit tests โ€” payment formula, schedule termination, monotonically decreasing balance, principal/interest totals, and prepayment savings:

npm test

A finance-meets-code project โ€” the domain I know, expressed in software.

About

Interactive loan amortization & mortgage schedule visualizer โ€” monthly payment, total interest, payoff date, balance chart, and prepayment savings. Built with React + Vite, amortization math from first principles and unit-tested.

Topics

amortizationfinancefintechjavascriptloan-calculatormortgagereactvite

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 โ€” GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800ร—600. No cookies required.