I’ve implemented Masonry.js successfully on a CMS collection of txt based elements, however I’m having a bit of trouble with the sorting. I’ve assigned a sorting rule through Webflow’s Designer “number: smallest to largest”. The rule seems to work for the first three elements, but then breaks putting number 5 and 6 before number 4 and so on…
I’ve tested in Chrome and Safari on my Macbook. Obv, no issue on mobile as the masonry layout is not triggered, with the elements stacking in the correct order
Hello @Davidlin_ch12 thank you for chipping is. I think you’re onto something there: the additional fixes the sorting by numbers (1 to 9) but it seems to “undo” the masonry effect, turning the list into a standard grid:
Looking at your live page, I see you have added ; after horizontalOrder. There should be nothing, when it is the last line because it is in JSON format. You should only add ; after Javascript.
Edit: also add a , after '.masonry-item'. Like the example in my last reply