Files
CHOMPStation2/code/modules/nano/_JSON.dm
ccomp5950 89652ae5e3 JSON caching for nanoui
You get to cache data, make the best of it.

NanoUI for PDA now won't shove the manifest through list2json every tick, it will cache the json for manifest and shove it into the cache_data so list2json tacks it onto the end.
2015-01-25 06:22:30 -05:00

13 lines
263 B
Plaintext

/*
n_Json v11.3.21
*/
proc
json2list(json)
var/static/json_reader/_jsonr = new()
return _jsonr.ReadObject(_jsonr.ScanJson(json))
list2json(list/L, var/cached_data = null)
var/static/json_writer/_jsonw = new()
return _jsonw.WriteObject(L, cached_data)