In the render of the SearchBar class, I can't get the unordered list with the injected Javascript to show in the browser. Is there an error in the method, or is there something more I have to do to get injected Javascript to appear?
import React from 'react';
import './searchbar.css';
const sortByOptions = {
"Best Match": "best_match",
"Highest Rated": "rating",
"Most Reviewed": "review_count"
}
class SearchBar extends React.Component {
renderSortByOptions() {
return Object.keys(sortByOptions).map(sortByOption => {
const sortByOptionValue = sortByOptions[sortByOption];
});
}
render() {
return (
<div className="SearchBar">
<div className="SearchBar-sort-options">
<ul>
{this.renderSortByOptions()}
</ul>
</div>
<div className="SearchBar-fields">
<input placeholder="Search Businesses" onChange={this.handleTermChange} />
<input placeholder="Where?" onChange={this.handleLocationChange} />
</div>
<div className="SearchBar-submit">
<a>Let's Go</a>
</div>
</div>
)
}
}
export default SearchBar;