Values prefixed with "dynamic-ratetable-" are simple injections in the format `dynamic-ratetable-key-lender`, used for getting scenario attributes like payment/loanamount/date for disclaimer data.
Lender | currentAsOfDate | rate | loanAmount | payment | discountPoints |
---|---|---|---|---|---|
lower | dynamic-ratetable-currentAsOfDate-lower | dynamic-ratetable-rate-lower | dynamic-ratetable-loanAmount-lower | dynamic-ratetable-payment-lower | dynamic-ratetable-discountPoints-lower |
quicken | dynamic-ratetable-currentAsOfDate-quicken | dynamic-ratetable-rate-quicken | dynamic-ratetable-loanAmount-quicken | dynamic-ratetable-payment-quicken | dynamic-ratetable-discountPoints-quicken |
wells | dynamic-ratetable-currentAsOfDate-wells | dynamic-ratetable-rate-wells | dynamic-ratetable-loanAmount-wells | dynamic-ratetable-payment-wells | dynamic-ratetable-discountPoints-wells |
bankMarketAvg | dynamic-ratetable-currentAsOfDate-bankMarketAvg | dynamic-ratetable-rate-bankMarketAvg | x dynamic-ratetable-loanAmount-bankMarketAvg | x dynamic-ratetable-payment-bankMarketAvg | x dynamic-ratetable-discountPoints-bankMarketAvg |
Values prefixed with "dynamic-rate- provide current rate for a lender and it's difference and direction from bankrate market avg. Nest the specific value desired inside a wrapper indicating the lender. For example: parent div has class="dynamic-rate-lower" and child spans use class="dynamic-rate-value" and class="dynamic-rate-diff".
Lender | Up/Down | Rate | Difference |
---|---|---|---|
lower dynamic-rate-lower | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
quicken dynamic-rate-quicken | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
wells dynamic-rate-wells | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
bankmarketavg dynamic-rate-bankmarketavg | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
Values prefixed with "dynamic-apr- provide current apr for a lender and it's difference and direction from bankrate market avg. Nest the specific value desired inside a wrapper indicating the lender. For example: parent div has class="dynamic-apr-lower" and child spans use class="dynamic-rate-value" and class="dynamic-rate-diff".
Lender | Up/Down | APR | Difference |
---|---|---|---|
lower dynamic-apr-lower | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
quicken dynamic-apr-quicken | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
wells dynamic-apr-wells | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
bankmarketavg dynamic-apr-bankmarketavg | UPDOWN dynamic-rate-increase dynamic-rate-decrease | dynamic-rate-value | dynamic-rate-diff |
Just like above but it only works for refirate and only works for value and only works for lower.
Lender | Rate |
---|---|
lower dynamic-refirate-lower | dynamic-rate-value |
The scope of the injectable data increased gradually through the initial project and then a ton after the initial release, adding 15/30 term data and full tables for refi. Time to refactor a bit. To keep it clean, I'm using a new prefix for the classes: ratedata-. The parent-child mechanism from above seems to be the best way to handle this, so we're going to elaborate on that.
Values prefixed with "ratedata- provide current rates and scenario information for a lender, including some computed values, like the difference between that rate and bankrate market avg. Nest the specific value desired inside a wrapper indicating that it is injectable, and then add data properties to select the right value.. For example: a parent div has class="ratedata" and properties data-lender, data-term, and data-loantype and child spans use class="ratedata-value" and class="ratedata-diff".
Loan | "Current As Of" Date | Scenario Loan Amount | Scenario Payment | Scenario Discount Points | Rate | Rate Up/Down | Rate Difference | APR | APR Up/Down | APR Difference |
---|---|---|---|---|---|---|---|---|---|---|
Lower 30yr Purchase class="ratedata" data-lender="lower" data-term="30" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Quicken 30yr Purchase class="ratedata" data-lender="quicken" data-term="30" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Wells 30yr Purchase class="ratedata" data-lender="wells" data-term="30" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Bankrate Market Avg 30yr Purchase class="ratedata" data-lender="bankMarketAvg" data-term="30" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Lower 15yr Purchase class="ratedata" data-lender="lower" data-term="15" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Quicken 15yr Purchase class="ratedata" data-lender="quicken" data-term="15" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Wells 15yr Purchase class="ratedata" data-lender="wells" data-term="15" data-loantype="purchase" | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Bankrate Market Avg 15yr Purchase | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Lower 30yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Quicken 30yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Wells 30yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Bankrate MarketAvg 30yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Lower 15yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Quicken 15yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Wells 15yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |
Bankrate MarketAvg 15yr Refinance | ratedata-currentAsOfDate | ratedata-loanAmount | ratedata-payment | ratedata-discountPoints | ratedata-rate | UPDOWN ratedata-rate-increase ratedata-rate-decrease | ratedata-rate-diff | ratedata-apr | UPDOWN ratedata-apr-increase ratedata-apr-decrease | ratedata-apr-diff |