0
反應組件上的UI。我有一個<BottomNavigationItem />
組件。這實際上呈現爲<button>
。我怎樣才能讓它呈現/導航到一個URL?Material-UI BottomNavigationItem URL
class FooterNavigation extends Component {
state = {
selectedIndex: 0,
};
select = (index) => this.setState({selectedIndex: index});
render() {
return (
<footer className="mdl-mini-footer">
<Paper zDepth={1}>
<BottomNavigation selectedIndex={this.state.selectedIndex}>
<BottomNavigationItem
label="Reviews"
icon={reviewIcon}
onClick={() => this.select(0)}
/>
</BottomNavigation>
</Paper>
</footer>
);
}
}