Render custom calculated field in a form
I have a form which takes some inputs and based on that inputs (number of persons) I need to calculate some price. Can I do that in a custom view field? How do I inject the current form state in that view? Or some parameters to display?