{"id":15358744,"url":"https://github.com/atsushisakai/pyjsonviewer","last_synced_at":"2025-05-09T00:08:46.776Z","repository":{"id":45225696,"uuid":"134559818","full_name":"AtsushiSakai/PyJSONViewer","owner":"AtsushiSakai","description":"A JSON viewer using pure python","archived":false,"fork":false,"pushed_at":"2021-12-30T06:14:09.000Z","size":312,"stargazers_count":87,"open_issues_count":6,"forks_count":32,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-05-09T00:08:38.548Z","etag":null,"topics":["json","json-data","python","python3","tkinter"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/PyJSONViewer/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AtsushiSakai.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-05-23T11:30:21.000Z","updated_at":"2025-01-11T23:54:26.000Z","dependencies_parsed_at":"2022-09-06T01:24:33.413Z","dependency_job_id":null,"html_url":"https://github.com/AtsushiSakai/PyJSONViewer","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AtsushiSakai%2FPyJSONViewer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AtsushiSakai%2FPyJSONViewer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AtsushiSakai%2FPyJSONViewer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AtsushiSakai%2FPyJSONViewer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AtsushiSakai","download_url":"https://codeload.github.com/AtsushiSakai/PyJSONViewer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253166521,"owners_count":21864482,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["json","json-data","python","python3","tkinter"],"created_at":"2024-10-01T12:42:33.527Z","updated_at":"2025-05-09T00:08:46.755Z","avatar_url":"https://github.com/AtsushiSakai.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"https://github.com/AtsushiSakai/PyJSONViewer/raw/master/img/icon.png\" align=\"right\" width=\"200\"/\u003e\n\n# PyJSONViewer\nA JSON file data viewer using pure python\n\n[![CI](https://github.com/AtsushiSakai/PyJSONViewer/actions/workflows/CI.yml/badge.svg)](https://github.com/AtsushiSakai/PyJSONViewer/actions/workflows/CI.yml)\n[![Downloads](https://pepy.tech/badge/pyjsonviewer)](https://pepy.tech/project/pyjsonviewer)\n[![Downloads](https://pepy.tech/badge/pyjsonviewer/month)](https://pepy.tech/project/pyjsonviewer)\n[![Downloads](https://pepy.tech/badge/pyjsonviewer/week)](https://pepy.tech/project/pyjsonviewer)\n\n# Gallery\n\n- Mac OS\n\n![img1](https://github.com/AtsushiSakai/PyJSONViewer/raw/master/img/mac.png)\n\n- Windows10\n\n![img1](https://github.com/AtsushiSakai/PyJSONViewer/raw/master/img/windows.png)\n\n- Ubuntu\n\n![img1](https://github.com/AtsushiSakai/PyJSONViewer/raw/master/img/ubuntu.png)\n\n\n# What is this?\n\nThis is a JSON file data viewer based on python.\n\nIt only uses built-in libraries of python (tkinter, json).\n\nFeatures:\n\n1. Minimum dependency. \n\n2. Multi-platform (Mac, Windows, Linux).\n\n3. Easy to use.\n\n\n# Requirements\n\n- Python 3.7 or higher\n\n# Download\n\n\u003e$ pip install PyJSONViewer\n\nor download as zip.\n\n- [PyJSONViewer · PyPI](https://pypi.org/project/PyJSONViewer/)\n\n# How to use\n\n## Select JSON file with CUI.\n\n1. Run pyjsonviewer with -f option and the path to a JSON file:\n\n\u003e $ pyjsonviewer -f path\\_to\\_json\\_file/sample.json\n\n2. JSON data tree will be shown.\n\n## Select JSON file with GUI.\n\n1. Run pyjsonviewer\n\n\u003e $ pyjsonviewer\n\n2. File-\\\u003eOpen and then select json file.\n\n3. JSON data tree will be shown.\n\nYou can set initial directory:\n\n\u003e $ pyjsonviewer -d path\\_to\\_json\\_file\\_dir\n\n## Select JSON file from history.\n\n1. Run pyjsonviewer.py\n\n2. File-\\\u003e\"Open from history\" and then double click a json file path from the list.\n\n![img1](https://github.com/AtsushiSakai/PyJSONViewer/raw/master/img/history.png)\n\n3. JSON data tree will be shown.\n\n## Select JSON file with drag and drop.\n\n1. Run pyjsonviewer.py with the option -o\n\n\u003e $ python pyjsonviewer.py -o path\\_to\\_json\\_file\\_dir\n\n2. File browser is shown.\n\n3. You can drag and drop a JSON file to the file browser.\n\n## Menu bar function\n\n- Expand all items: Tools -\u003e Expand all\n\n- Collapse all items: Tools -\u003e Collapse all\n\n- Show version: Help -\u003e About\n\n- Show github page: Help -\u003e GitHub page\n\n- Show release note: Help -\u003e Release note\n\n## Inside python code\n\n### View json file\n```\nimport pyjsonviewer\n\npyjsonviewer.view_data(json_file=\"dat/list.json\")\n\n```\nJSON data tree will be shown.\n\n### View json object\n```\nimport pyjsonviewer\njson_object = {\"a\":[1,2,3], \"b\":\"test\"}\npyjsonviewer.view_data(json_data=json_object)\n```\nJSON data tree will be shown.\n\n## Vimrc setting\n\nIf you are a vim user, you can set this command in your vimrc.\n\n\t\"JSON format\n\tfunction! JsonFormat()\n\t\t%!python -m json.tool\n\tendfunction\n\tcommand! JsonFormat :call JsonFormat()\n\n\t\"JSON viewer\n\tfunction! JsonViewer()\n\t\t\"%!python -m pyjsonviewer -f % \u003e /dev/null\n  \t\tlet filename = expand('%')\n\t\tlet s:job = job_start(\n\t\t\\   [\"/bin/sh\", \"-c\", \"python -m pyjsonviewer -f\".filename],{})\n\tendfunction\n\tcommand! JsonViewer :call JsonViewer()\n\nWhen you are editing a json file with vim,\n\nyou can open it using PyJSONViewer with\n\n\u003e: JSONViewer()\n\nYou can also format json file with\n\n\u003e: JSONFormat()\n\n# Open a link with a browser\n\nIf a URL is included in a json file,\n\nyou can open it with a browser with double click the URL.\n\n# License \n\nMIT\n\n# Author\n\n- [Atsushi Sakai](https://github.com/AtsushiSakai/) ([@Atsushi_twi](https://twitter.com/Atsushi_twi))\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatsushisakai%2Fpyjsonviewer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fatsushisakai%2Fpyjsonviewer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatsushisakai%2Fpyjsonviewer/lists"}