0

Suppose i have array like this

[
    ['suplier1']
    ['suplier1']
    ['suplier1']
    ['suplier2']
    ['suplier2']
    ['suplier3']
    ['suplier3']
    ['suplier4']
]

And I want to create html element dynamically like below using loop

<div>
   <div>
     Supplier 1
     Supplier 1
     Supplier 1
   </div>
   <div>
     Supplier 2
     Supplier 2
   </div>
   <div>
     Supplier 3
     Supplier 3
   </div>
   <div>
     Supplier 4
   </div>
</div>

How can i do this ?

Note : i am implementing this stuff in knockout, i have added extension attribute of supplier in shipping method and i want to display supplier wise shipping method

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.