Sublime Text Suite Introduction (iv): Pretty JSON

Source: Internet
Author: User
Tags sublime text

JSON, a lightweight material in the language, so many web site Ajax request response results are in JSON format below is a standard JSON format
{     "firstName": "John",     "LastName": "Smith",     "male": true,     "age": +,     "address":      {         " StreetAddress ": 2nd Street", "City         ": "New York", "State         ": "NY",         "PostalCode": "10021"     },     " PhoneNumber ":      [         {"           type ":" Home ",           " number ":" 212 555-1234 "         },         {           " type ":" Fax ", "Number           ": "646 555-4567"         }     ] }
But the reality is cruel, often you can not see it so good to understand the JSON format, usually you will only see the following
{"FirstName": "John", "LastName": "Smith", "male": true, "age": +, "address": {"streetaddress": "2nd Street", "City": " New York "," state ":" NY "," PostalCode ":" 10021 "}," PhoneNumber ": [{" Type ":" Home "," number ":" 212 555-1234 "},{" type ":" Fax "," number ":" 646 555-4567 "}]}
If there are non-English language words, it is more dire, as shown below
{"ret": {"status": "false", "MSG": "\u9801\u9762\u5df2\u904e\u671f\uff0c\u8acb\u91cd\u6574\u8a72\u9801\u9762"}}
All become Unicode encoded ... Only the computer can understand what the hell ... In general circumstances may be dropped to the JSON Parser online or JSON pretty print and other Web sites to parse in otherwise is through the browser console to solve the code, there are many ways to solve the code, then it is to introduce how through the sublime Text directly parses the original format of JSON format Hot key: CTRL + ALT + J Pretty JSON Github:https://github.com/dzhibas/sublimeprettyjson detailed installation steps, please continue to look down
    • Focus
    • Discuss
1. Please make sure that the package Control is installed
If it is not installed, see: Installation of the first sublime text kit

2. Press CTRL + SHIFT + p and enter the package Control:install Package3. In the input pretty JSON, press ENTER to complete the installation 4. Press Preferences > Package Settings > Pretty JSON > Settings-default? tuning setting 5. The following is the setting, the preset is very useful, not so good to set out

Sublime Text Suite Introduction (iv): Pretty JSON

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.