Skip to content

About

Explore JSON, JSONC, and YAML as interactive graphs beside editable source in Orca.

Topics

Resources

Stars

10 stars

Watchers

0 watching

Forks

Repository files navigation

JSON Visualizer

JSON Visualizer — See the shape of your data. Click the pen icon beside Source to visualize.

Explore ordinary JSON, JSONC, and YAML files as interactive graphs in Orca. Edit source on the left, inspect connected objects and values on the right, and save through Orca.

An unofficial Orca port of JSON Crack, built with its jsoncrack-react visualization component. JSON Visualizer has its own name and branching-node icon and is not affiliated with or endorsed by the upstream project.

Install

Requires Orca desktop 1.4.248 or newer.

  1. Open Settings → Plugins.

  2. Choose Add plugin → From a Git URL… and enter:

    https://github.com/faisalmuhammad/orca-json-visualizer#v0.1.0
    

    Keep #v0.1.0 at the end to install this release tag.

  3. Review and approve the requested access: a sandboxed custom editor that reads and edits the file opened in it.

  4. Open a JSON or YAML file, then click the pen icon beside Source to switch to JSON Visualizer.

All runtime assets are included. Installation requires no Node.js, dependencies, or build step.

The plugin uses an isolated desktop frame and asks for no workspace, storage, secret, or network capabilities. Its document access is limited to files opened in its editor.

The manifest's API floor is Orca 1.4.248. The first release is verified on macOS with the installed Orca desktop app; the minimum-version binary and Windows/Linux have not been separately verified. Browser clients fall back to Source.

Preview

Dark Light
JSON source and graph in dark appearance JSON source and graph in light appearance
Paths and source locations YAML
Customer name tooltip with its path and source location YAML graph preserving a large integer

Screenshots show the compiled viewer with sample documents and a document-host fixture, using Monospace app-theme color tokens. See capture details.

Open a file

Open an existing .json, .jsonc, .yml, or .yaml file, then click the pen icon for JSON Visualizer in Orca's editor view selector beside Source. The extension selects JSON or YAML automatically, and comments or trailing commas select JSONC syntax. The source toolbar shows the detected format.

Orca keeps ordinary JSON and YAML files in Source by default, including when a plugin requests default priority. Selecting the visualizer is supported entirely through Orca's existing plugin API. The view-selector button uses Orca's generic pen icon; the plugin icon appears in the file tab, plugin listing, and viewer header.

Features

  • Resizable Monaco source pane with diagnostics, find, folding, and undo/redo. Hide Source to give the graph more room.
  • Drag to pan and scroll the middle mouse wheel to zoom around the pointer. Fit, root focus, four layout directions, a subtle grid, and collapse/expand controls are available in a floating dock.
  • Hover a node row for its path, type, exact source preview, and line/column. Focus a node with the keyboard for its tooltip; Escape dismisses it. Click a node to inspect its full original value and reveal it in Source.
  • Automatic JSON/JSONC detection, including comments and trailing commas; YAML syntax highlighting and parse diagnostics.
  • YAML mappings, sequences, block strings, anchors, and bounded alias expansion. Multiple YAML documents appear as an outer array.
  • Native saving preserves raw text, duplicate keys, line endings, comments, and large-number spelling. Formatting is an explicit, undoable edit.
  • Invalid drafts remain editable and savable; the last valid graph is visibly marked stale.
  • External edit conflicts retain both drafts and require an explicit choice before saving. Read-only files remain available for exploration.
  • Orca theme integration, independent state per tab, and locally packaged graph, layout, and editor workers.

Graph preview is bounded to 768 KiB of UTF-8 source, 128 nesting levels, 500 nodes, 2,000 object rows, 24,000 scanner tokens, and 4,096 characters per literal. Documents exceeding a graph limit retain their source editor. Duplicate-key inspection resolves the first matching key and shows a warning.

YAML saves preserve the original text. Formatting retains comments, anchors, scalar values, number spelling, and CRLF, while adjusting whitespace and quoting. Alias tooltips point to the alias; descendants point to the anchor's original source. Preview allows up to 100 expanded aliases and refuses cycles, complex mapping keys, overlapping graph keys, and non-finite numbers. YAML merge keys (<<) appear literally. Duplicate YAML keys produce a parse error. XML and CSV support remains planned.

Build and verify

Build tooling requires Node 22.12 or newer. From this folder:

For local development, add this folder through Settings → Plugins → Development folders and enable it.

orca plugin types . --json
npm --prefix build ci
npm --prefix build run typecheck
npm --prefix build run build
npm --prefix build test
npm --prefix build run check

The build pins dependencies with its lockfile and packages all runtime assets locally. Its npm configuration accepts legacy React peer declarations in upstream transitive packages; actual graph behavior is covered by browser tests. Set ORCA_CLI_COMMAND to the Orca CLI executable if it is not on your PATH.

Browser interaction checks run against the compiled assets with a document-host fixture. Native document race tests use Orca's actual test host.

cd build
npx playwright install chromium
npm run test:browser

Set JSON_VISUALIZER_BROWSER to an existing compatible Chromium executable to reuse a browser installation.

Create a runtime-only folder, deterministic ZIP, and SHA-256 checksum:

npm --prefix build run package

Artifacts are written to the sibling json-visualizer-release/ folder, outside the plugin. The package excludes dependencies, build sources, test fixtures, generated Orca types, and social-preview artwork. Nothing is published by these commands. Development details are in build/README.md.

Release artwork and screenshot generation, verification, and publication steps are documented in RELEASE.md. Version changes are in CHANGELOG.md.

Attribution and licenses

Original integration code and artwork are MIT licensed. The graph component and Reaflow are Apache-2.0; ELK is EPL-2.0. Their licenses remain separate from the wrapper license. See third-party notices, included original license files, and documented upstream adaptations.

About

Explore JSON, JSONC, and YAML as interactive graphs beside editable source in Orca.

Topics

Resources

Stars

10 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages