How to create html structure which will allow only 3 div elements in each li. In React + underscore.js
问题 For creating this structure i want to use only underscore.js methods. I have below array . var xyz = [{ 'name': 'test' },{ 'name': 'test1' },{ 'name': 'test2' },{ 'name': 'test3' },{ 'name': 'test4' },{ 'name': 'test5' }]; And HTML structure should create like this - <ul> <li> <div><span>test3</span></div> <div><span>test4</span></div> <div><span>test5</span></div> </li> <li> <div><span>test6</span></div> <div><span>test7</span></div> <div><span>test8</span></div> </li> </ul> I am using React