Simple Example of jQuery deep copy Json object and jqueryjson
This document describes how to implement jQuery's deep copy of Json objects. We will share this with you for your reference. The details are as follows:
Var oldJson = {Name: 'quber', List: [1, 2, 3, 4], Obj: [{name: 'qubernet', fun: function () {return 1 ;},{ name: 'qubernet1', fun: function () {return 2 ;}}]}; var newJson =$. extend (true, {}, oldJson); console. log (JSON. stringify (newJson ));
PS: I recommend several json online tools for you here. I believe they can be used in future development:
Online JSON code verification, validation, beautification, and formatting tools:
Http://tools.jb51.net/code/json
JSON online formatting tool:
Http://tools.jb51.net/code/jsonformat
Online XML/JSON conversion tools:
Http://tools.jb51.net/code/xmljson
Json code online formatting/beautification/compression/editing/conversion tools:
Http://tools.jb51.net/code/jsoncodeformat
C language style/HTML/CSS/json code formatting and beautification tools:
Http://tools.jb51.net/code/ccode_html_css_json