Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to access match object in class component

class Generic extends React.Component {
constructor(props) {
    super(props);
}

render() {
    return (
        <div className="wrapper">
            <div className="section">
                <div className="container">
                    <h3>Menu : {this.props.params.id}</h3>
                </div>
            </div>
        </div>
    );
}
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #access #match #object #class #component
ADD COMMENT
Topic
Name
9+5 =