Binquan Wang Binquan Wang - 1 year ago 80
Javascript Question

why my collapse default is not hidden

render() {
var item =
return (
<li key={} className="faq-item-li" id={"faq-item-li-" + item.counter}>
<h4 data-toggle="collapse" data-target={"#answer"+} >{item.title}</h4>
<div id={"answer"+} class="collapse">{item.description}</div>

part default is always shown. I want this part to be hidden first

Answer Source

Try replacing class='collapse' by className='collapse'

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download