@justinbmeyer justinbmeyer released this Oct 25, 2018 · 107 commits to master since this release

Assets 2

can-stache

It adds 3 new helpers:

  • or( first, second, third )
  • and( first, second, third )
  • not( value ) - this is a converter copied from can-stache-converters

These can be used in combination like:

{{# if( not( and( user.isAdmin, user.isSuperAdmin ) ) ) }}

It makes views callable within stache. The following passes addressView to view where view calls it:

const addressView = stache(`<address>{{this.street}}, {{this.city}}</address>`);

const view = stache(`{{ addressView(street=user1.street city=user1.city) }}`)

view({
  addressView
});

Inline partials callable too:

        {{< addressView }}
            <address>{{ this.street}}, {{ this.city }}</address>
        {{/ addressView }}
        <h2>{{ this.user1.name }}</h2>
        {{ addressView(user1) }}

This re-orgs the docs towards being use-case first:

image

This also deprecates much of the older ways of doing things:

image

Notice that partials are now deprecated. Call expressions are now favored.

can-attribute-observable

can-bind

  • Use can-assign instead of Object.assign
  • Fix Set instantiation
  • Use can-reflect-dependencies@1.1.1

can-control

import canSymbol from "can-symbol";

element[canSymbol.for("can.controls")] //-> controls

can-dom-events

can-dom-mutate

can-event-queue

Commit: canjs/can-event-queue@e37851f

can-fixture

can-observation

can-query-logic

can-reflect

can-reflect-dependencies

  • Use can-assign instead of Object.assign
  • Fix Set instantiation

can-stache-converters

can-view-live

  • Fix usage ChildNode.remove in tests
  • Fix usage of HTMLDocument.contains and HTMLDocument.ownerDocument

can-view-scope

Issue: canjs/can-stache#616

Makes stuff like this work: {{ this.todo.isSaving() }}.