How to use the @sitecore-jss/sitecore-jss-angular.getChildPlaceholder function in @sitecore-jss/sitecore-jss-angular

To help you get started, we’ve selected a few @sitecore-jss/sitecore-jss-angular 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 Sitecore / jss / samples / angular / src / app / components / styleguide-layout-tabs / styleguide-layout-tabs.component.ts View on Github external
update() {
    this.tabs = getChildPlaceholder(this.rendering, 'jss-tabs').filter((tab: ComponentRendering) => tab.fields) as ComponentRendering[];

    if (!this.activeTab && this.tabs.length > 0) {
      this.activeTab = this.tabs[0];
    }
  }
}

@sitecore-jss/sitecore-jss-angular

This module is provided as a part of Sitecore JavaScript Rendering SDK (JSS). It contains Angular integration components and services for JSS.

Apache-2.0
Latest version published 18 days ago

Package Health Score

57 / 100
Full package analysis

Similar packages