Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
domReady(() => {
//update first
this.update()
//init mdc tab
this.data.tabBar = new MDCTabBar(this.shadowRoot.querySelector('.mdc-tab-bar'));
this.data.tabBar.listen('MDCTabBar:activated', (e) => {
let item = this.props.children[e.detail.index]
this.fire('change', item.attributes)
})
})
}
public componentDidMount() {
super.componentDidMount();
if (this.control) {
this.MDComponent = new MDCTabBar(this.control);
}
this.afterComponentDidMount();
}