Kirby Builder not reordering blocks in the text-file


not sure if this is a general limitation with how kirby handles the reordering of blocks in a structured content entry, but this happens in Kirby Builder as well.

The only problem I have with this is that I cannot properly target the correct order of how the blocks appears in the fronted / panel, by adding logic and styles, if the content blocks in the page.txt keeps the ‘original’ order.

So say I add an image and a text block and hit save. Then add another image and I move it up right after the first image, in the page.txt the order gets saved as

- image
- text
- image

Would it be possible to fix this by using a post-hook?

Can you maybe post your code? I have a site that makes heavy use of builder, with about 6 builder controlled components and some pages have a dozen of these on the page. Ive reordered them fine without seeing your issue.

Also what Kirby version and builder version are you using? There was a security release of Kirby recently that you are strongly advised to update to.

very weird for some reasons i was printing out the kirby builder object and it did not change at first, but might have been my mistake.

checking the text-file, it actually report the changes accurately.