score:2

Accepted answer

Try this approach,

<ul>
      {
        data.map((item)=>(
          <li
          className="col-xs-6 col-sm-4 col-md-4 col-lg-3"
          data-src={item?.img}
          data-sub-html={`<h4>${item?.title}</h4><p>${item?.desc}</p>`}
          >
            <a style={{ cursor: 'pointer' }}>
             <img className="img-responsive" src={item?.img} alt="Thumb-1" />
           </a>
          </li> ))
        }
  </ul>

Related Query

More Query from same tag