Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import React, { Component } from 'react';
- import './App.css';
- import SelectBrand from './components/SelectBrand'
- import SelectModel from './components/SelectModel'
- class App extends Component {
- state = {}
- render() {
- return (
- <div className="form">
- <SelectBrand
- value={this.state.brand_id}
- onChange={brand_id => this.setState({ brand_id })}
- />
- <SelectModel
- value={this.state.model_id}
- onChange={model_id => this.setState({ model_id })}
- brandId={this.state.brand_id}
- />
- </div>
- );
- }
- }
- export default App;
Add Comment
Please, Sign In to add comment