Rendering lists in Alpine.js

displaying the items of an array as a list
2025-09-28 21:33 // updated 2025-12-11 18:30

Provided we have an array encoded in JSON we can easily display its items in the form of a list with a very streamlined x-for syntax:

Note that we also use the shorthand syntax for x-bind:key (:key) so that each list item has a unique identifier!

âŦ…ī¸ older (posts)
🛞 "wheel" + "cycle" + "chakra"
newer (posts) âžĄī¸
2025-09 đŸĒļ