Google Drive Realtime API - Adding Collaborative list -


from documentation, says can have collaborative list contains other collaborative objects, namely collaborative list. therefore in "onfileloaded" event, have following code:

var myroot = doc.getmodel().getroot().get('mylist'); var newlist = doc.getmodel().createlist(); newlist.push('level2'); myroot.push(newlist); 

i understand everytime reload file, new list added "mylist". works fine except when reload document, that's when api give me "mylist" , "newlist" gone , disappeared thin air. if add string or other data, data persist when reload document, not adding list current list. doing wrong? in advance.

i not sure why above not work me, when moved list adding codes out of "onfileloaded", specifically, adding list lists when click on dom element, works fine. supposed these codes should out of "onfileloaded" anyways, it's , find these useful.


Comments