0

I am trying to make the following code work:


{
   (this.props.fill_sett_list ? (this.props.fill_sett_list.map(fill_sett_list_item => (
                                <td>{fill_sett_list_item.filled_val}</td> ))) : 
                      (<td><a href="#/filledsetting"><button className='btn btn-primary btn-sm'>FILL</button></a></td>))
}

Unable to understand why the second part i.e. the else doesn't show up. It becomes blank.

The reducer:

fillReducer
   fill_sett_list(pin): []
Sid
  • 3,749
  • 7
  • 29
  • 62

0 Answers0