Skip to content

Improved component/template relationship

Choose a tag to compare

@g105b g105b released this 11 Dec 16:31
fcccb78

This release has two slight backwards-breaking changes:

  1. Binding lists with bindList and bindNestedList can no longer use associative arrays for the data structure, because there is not any way of differentiating between an associative array and any other type of list of data structures. If you are using associative arrays, you will need to indicate that the array is actually a data structure and not a list by casting to an object. This is good practice anyway - arrays should only contain a list of things, objects can be used to describe data.
  2. HTML components that have the data-template attribute on the component tag, rather than on the contained tag(s), can not be used if the component consists of multiple root elements. This is an edge-case and improves the readability by forcing component usage to be more expected.