Custom Mortgage Overpay Calculator plugin built for WordPress websites.
- Typescript
- React (frontend UI)
- Tailwind CSS (styling)
- GSAP (simple animations)
- A bit of PHP (WordPress plugin glue / asset enqueueing)
The calculator supports mortgage overpayment simulations with these inputs and behaviors:
- Loan Amount (pl. Kwota kredytu) — principal amount
- Nominal Interest Rate (pl. Oprocentowanie nominalne) — annual nominal %
- Repayment Period (pl. Okres spłaty) — months input for schedule
- Installment Type (pl. Rodzaj spłacanych rat) — equal vs declining installments
- Overpayment Effect (pl. Skutek nadpłaty) — reduce monthly payment or shorten term
- Overpayment Type (pl. Rodzaj nadpłaty) — one-time or recurring
- Overpayment Amount (pl. Kwota nadpłaty kredytu) — amount of extra payment to apply
Extra UX niceties included:
- Detailed schedule view (per-month rows)
- Inline editing of one-time extras in schedule + hint/toast to apply changes
- Smooth entry animations using GSAP
# go to the front-end folder
cd front-end
# install dependencies
npm iTo start the app in a local/test environment:
# go to the front-end folder
cd front-end
# run dev server
npm run devOpen the dev server URL printed by your tooling and test the calculator UI. Usually it is localhost:5173 if you use vite.
To produce a distributable plugin ZIP that can be uploaded to a WordPress site, follow these steps:
- Build production assets in the front-end:
This should produce
# go to front-end folder cd front-end # build project npm run build
dist/directory - Prepare the plugin package:
- In the
front-enddirectory remove source files you don't want in the final plgin, keeping only thedist/folder that contains built assets - Ensure that WordPress PHP plugin file
OverpayCalculator.phpis present in the package root folder
- In the
- Zip the plugin directory
- Upload the produces ZIP to WordpPress: admin → Plugins → Add New → Upload Plugin.
/ (repo root)
├─ front-end/
│ ├─ src/
│ ├─ dist/
│ └─ package.json
├─ OverpayCalculator.php
└─ README.md