Skip to content

Instantly share code, notes, and snippets.

<button local-class="run" type="button" {{on "click" (perform this.countToTenTask)}}>Run the global countToTenTask via a local task</button>
<button local-class="run" type="button" {{on "click" (perform @count)}}>Run the global countToTenTask directly</button>
import Component from '@glimmer/component';
import { tracked } from '@glimmer/tracking';
class ObjectWithTrackedProperties {
@tracked attribute = "tracked value";
nonTrackedAttribute = "non tracked value";
}
class ObjectWithTrackedProperties2 {
@tracked anotherAttribute = "another tracked value";
<p>{{this.counter}}</p>
<button {{on "click" this.doStuff}}>click me</button>