Currently the communication from Lua to JS via C requires complex data structures (Lua tables) to be serialized to JSON in Lua before passed on as a string to the extension and deserialized again in Javascript. The same process but in reverse goes for complex responses from Javascript back to Lua.
The preferred solution is to pass Lua tables to C and let the C code serialize to JSON. Currently there's no support for serializing a Lua table to JSON from C.
Task: Evaluation of JSON parsers in C. Integrate with extension.
Perhaps Lua table to JSON and back again should be part of the DMSDK?
Currently the communication from Lua to JS via C requires complex data structures (Lua tables) to be serialized to JSON in Lua before passed on as a string to the extension and deserialized again in Javascript. The same process but in reverse goes for complex responses from Javascript back to Lua.
The preferred solution is to pass Lua tables to C and let the C code serialize to JSON. Currently there's no support for serializing a Lua table to JSON from C.
Task: Evaluation of JSON parsers in C. Integrate with extension.
Perhaps Lua table to JSON and back again should be part of the DMSDK?