@wealthx/borrow-capacity-lib
v2.1.9
Published
Borrow capacity calculation library for WealthX
Readme
@wealthx/borrow-capacity-lib
A centralized TypeScript library for finance data computations used across WealthX applications.
Overview
This package provides a comprehensive set of financial calculations including:
- User Metrics: LVR, equity, excess monthly surplus calculations
- Borrow Capacity: Loan capacity and repayment calculations
- HEM Calculations: Household Expenditure Measure calculations for Australia
- History Data Processing: Scenario finance history aggregation
Installation
yarn add @wealthx/borrow-capacity-libTypes
The library exports comprehensive TypeScript types for all calculations:
import {
AccountCategory,
AccountType,
UserFinanceData,
MonthlyFinanceData,
BorrowCapacityParams,
HEMCalculationParams,
PeriodType,
// ... and many more
} from "@wealthx/borrow-capacity-lib";Testing
Run the test suite:
yarn testRun tests with coverage:
yarn test:coverageDevelopment
Setup
# Use the correct Node.js version
nvm use
# Install dependencies
yarn installBuilding
yarn buildLinting
yarn lint
yarn lint:fixFormula References
- Borrow Capacity: Based on WealthX Finance Documentation
License
UNLICENSED - Private package for WealthX internal use only.
Contributing
This is a private package. Please follow the established patterns and ensure all calculations have corresponding test cases.
