I just released v.3.0 of JSONItem_MTC , the drop in replacement for the classic framework JSONItem.
This version does a few things. First, I did away with the pragmas to disable background tasks and checks. Why? First, it didn't make much difference in speed anyway. Second, it would tie things up when encoding large JSON.
Second, I made memory usage more efficient when turning the JSON into a string. Rather than using one ever-expanding MemoryBlock, it creates a series of MemoryBlocks to hold the output and joins them at the end. As such, it can serialize a 500 MB JSON without issue. (Larger strings will give Xojo fits, it seems.)
I also added a few more tests to the harness project.
If you're using JSONItem, I encourage you to consider this instead. JSONItem has a few issues that have been solved by this class, as illustrated by the included unit tests. (See the README for some of the details.) And it's faster to boot.
Edit: Oh yeah, I also added an Operator_Subscript so you can both assign and retrieve values from an Array-type JSON with a simple index. For example:
dim j as new JSONItem_MTC( "[1, 2]" ) dim i as integer = j( 0 ) j( 1 ) = true