Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
componentDidMount() {
this.foundation = new MDCTabBarFoundation(this.adapter);
this.foundation.init();
const {activeIndex, indexInView} = this.props;
if (this.tabList[activeIndex]) {
// new DOMRect is not IE11 compatible
const defaultDOMRect = {
bottom: 0,
height: 0,
left: 0,
right: 0,
top: 0,
width: 0,
x: 0,
y: 0,
};
this.tabList[activeIndex].activate(defaultDOMRect /* previousIndicatorClientRect */);
}