added some REST stuff, added demo of JSONeditor, some rewriting. not finished yet