Probably not worth changing / maybe not even ideal, but this div exemplifies what I feel is a tendency of knockout to promote code that is hard to read, maintain, and debug because it doesn't encourage separation of logic and presentation.  Specifically, things like

```html
<div class="collapse" data-bind="foreach: settings, attr: {id: id}, css: {'in': !$data.collapse || _(settings).some(function (s) {return s.hasError();})}">
```

```html
<span data-bind="template: $data.widget_template || 'CommcareSettings.widgets.' + widget">
```

It seems like extracting the JS expressions into well-named computed properties of the model would be better all around.

It gives you sparser templates, syntax highlighting, pushing errors into javascript instead of the knockout parser/interpreter for bindings defined in html.