React - React-select customOption

0 votes
272 views
added May 14, 2019 in React by LC Marshal Captain (25,790 points)
<div className="col-12">
    <div className="row no-gutters">
        <div className="col-10">
        <AsyncCreatableSelect
            allowCreateWhileLoading
            isClearable
            className="location-search-wrapper"
            placeholder="Search yur place here"
            classNamePrefix="loc-search"
            loadOptions={this.getKeyword}
            onChange={this.handleSearchChange}
            components={{ Option: this.CustomOption }}
        />
        </div>
        <div className="col-2">
        <button type="button" onClick={this.goTo} className="btn btn-primary search-button"><i className="material-icons search-icon">search</i></button>
        </div>
    </div>
</div>

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...