How to use the @glimmer/reference.createTag function in @glimmer/reference

To help you get started, we’ve selected a few @glimmer/reference examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component.ts View on Github external
init() {
      this._super(...arguments);
      this[IS_DISPATCHING_ATTRS] = false;
      this[DIRTY_TAG] = createTag();
      this[BOUNDS] = null;

      if (DEBUG && this.renderer._destinedForDOM && this.tagName === '') {
        let eventNames = [];
        let eventDispatcher = getOwner(this).lookup('event_dispatcher:main');
        let events = (eventDispatcher && eventDispatcher._finalEvents) || {};

        // tslint:disable-next-line:forin
        for (let key in events) {
          let methodName = events[key];

          if (typeof this[methodName] === 'function') {
            eventNames.push(methodName);
          }
        }
        // If in a tagless component, assert that no event handlers are defined
github glimmerjs / glimmer.js / packages / @glimmer / application / src / components / component-managers / custom.ts View on Github external
getTag({ args }: CustomComponentState): Tag {
    if (isConst(args)) {
      // returning a const tag skips the update hook (VM BUG?)
      return createTag();
    } else {
      return args.tag;
    }
  }
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component-managers / outlet.ts View on Github external
getTag(): Tag {
    if (ENV._DEBUG_RENDER_TREE) {
      // returning a const tag skips the update hook (VM BUG?)
      return createTag();
    } else {
      // an outlet has no hooks
      return CONSTANT_TAG;
    }
  }
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component-managers / custom.ts View on Github external
getTag({ args }: CustomComponentState): Tag {
    if (isConst(args)) {
      // returning a const tag skips the update hook (VM BUG?)
      return createTag();
    } else {
      return args.tag;
    }
  }
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component-managers / template-only.ts View on Github external
getTag() {
    if (ENV._DEBUG_RENDER_TREE) {
      // returning a const tag skips the update hook (VM BUG?)
      return createTag();
    } else {
      // an outlet has no hooks
      return CONSTANT_TAG;
    }
  }
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component-managers / input.ts View on Github external
getTag() {
    if (ENV._DEBUG_RENDER_TREE) {
      // returning a const tag skips the update hook (VM BUG?)
      return createTag();
    } else {
      // an outlet has no hooks
      return CONSTANT_TAG;
    }
  }
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / helper.ts View on Github external
init() {
    this._super(...arguments);
    this[RECOMPUTE_TAG] = createTag();
  },
github emberjs / ember.js / packages / @ember / -internals / glimmer / lib / component-managers / mount.ts View on Github external
getTag(state: EngineState): Tag {
    let tag: Tag = CONSTANT_TAG;

    if (state.modelRef) {
      tag = state.modelRef.tag;
    }

    if (ENV._DEBUG_RENDER_TREE && isConstTag(tag)) {
      tag = createTag();
    }

    return tag;
  }
github glimmerjs / glimmer.js / packages / @glimmer / tracking / src / tracked.ts View on Github external
tagFor(key: string): DirtyableTag {
    let tag = this.tags[key];
    return tag === undefined ? (this.tags[key] = createTag()) : tag;
  }
}