Refactor our Handlebars helper logic into the Backbone view
Closed this issue · 0 comments
modulitos commented
In PR #435 we added lots of extra logic into our each_place_item
Handlebars Helper, shown here: https://github.com/smartercleanup/platform/pull/435/files#diff-84b7065ac0f6c9065befa0b524ce0d81L174
Perviously, that helper was making minor changes to the context passed from our place-detail
view into our place-detail
template. But with our new dynamic forms feature, we need to make a lot more changes to the context as we pass it into our template. Thus, we added a lot more pre-processing logic via #435, and the each_place_item
helper method has become quite long. We should try and move that method into our view, and be explicit that it is performing a pre-processing task.