Stop ColdFusion from sorting my structs/arrays

前端 未结 1 2022
甜味超标
甜味超标 2020-12-21 08:09

I have data represented in CF as an array of structs e.g.:

var foo = [{key = \'bar\', value = \'baz\', ... }...];

This structure gets itera

相关标签:
1条回答
  • 2020-12-21 08:46

    If your collection is expected to be ordered you need to use an array.

    Structs don't guarantee any ordering, and shouldn't be used as such.

    0 讨论(0)
提交回复
热议问题