Category : data-class

so, I heard there are no ternary operators in kotlin, so, how can I achieve the following in kotlin data class JS {online.map(function(item){ return ( <div key={item.uid} > {item.Gender== ‘Male’ ? <li > <div><img src={item.photoURL}/><p><b>{item.displayName}</b></p></div> </li> : null} </div> ) })} online is an object that contains the list of user information {item.Gender === ‘Male’ ..

Read more