R
R
Rufix2019-10-30 23:52:30
Vue.js
Rufix, 2019-10-30 23:52:30

Why doesn't Vue code work under seemingly identical conditions?

Here is the code at random
Application - mortgage calculator.
The problem is that in the form that it is given - the code works. The paragraphs inside this code were created personally for themselves in order to check the correctness of the value. I added the code, everything seems to be working - I decide to delete these paragraphs, because they are no longer needed. As a result, the code without these paragraphs does not work. Why?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
O
origami1024, 2019-10-31
@Rufix

You don't call getMonthRate and getCoefficient anywhere (except when shown in these paragraphs) which count intermediate data. Call these computed on input changes.
This is how it works, although the code turned out to be a little crutch

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question