Skip to content

2.1.0 Object Context

Latest

Choose a tag to compare

@theodorejb theodorejb released this 12 Jun 19:32

Added

  • Objects can now be used as context values alongside arrays. {{#each}} over an object iterates its public properties (#18).
  • .length on strings is now supported.
  • {{#each}} now accepts Traversable inputs, including generators, without buffering them into an array first.

Changed

  • Strict mode errors now report the type of the value a missing property was looked up on (e.g. "bar" not defined in array).

Fixed

  • In compat mode, a property explicitly set to null no longer falls through to parent scopes, matching Mustache behavior.