RKIf you are passing it as props then use this.props.type else this.state.type . It will workComment·Thread·Feb 21, 2020·Custom React Component Attribute