now sending json to view, which interprets it as a javascript object