ekwonye-richard / react-flags-select

Customizable svg flags select components for React Js
197 stars 121 forks source link

flags select box initial loading country flag didn't show #44

Closed Sirajul-haq closed 3 years ago

Sirajul-haq commented 4 years ago

React-flags-select initial loading country flag didn't show . When I select one region, then the flag showed.

import ReactFlagsSelect from 'react-flags-select';
import 'react-flags-select/scss/react-flags-select.scss';

const LocalSelect = () => {

return ( 

 <ReactFlagsSelect
  searchable={true}
  searchPlaceholder="Search"
  className="menu-flags"
  defaultCountry="US"
  showSelectedLabel={true} />     

 )
}

Screenshot_2020-03-12 React App

ekwonye-richard commented 3 years ago

defaultCountry has be removed in v2 and replaced with selected which is a more stable approach