Skip to content

[P1] Audit: JSON Formatter lacks direct download/export of formatted output #115

Description

@baixiangcpp

Imported from the byteflow.tools deep audit on 2026-06-22.

Problem: JSON Formatter supports format, minify, copy output, and file import, but the formatted or minified result does not have an obvious direct download/export action. Users who import a JSON file often expect to save the cleaned result as a new .json file.

Affected URL:

Reproduction steps:

  1. Open JSON Formatter.
  2. Click Try Example or import a JSON file.
  3. Click Format or Minify.
  4. Look for a Download or Export JSON action for the output.
  5. Attempt to save the formatted output as a local file.

Expected behavior: formatted and minified output should be downloadable as a .json file, with a safe default filename and file size feedback.

Actual behavior: output can be copied, but direct output download is not obvious or unavailable.

Impact: users handling files must copy/paste into another editor, which adds friction and can introduce mistakes.

Proposed fix:

  • Add Download Output button beside Copy Output.
  • Support .json download for formatted/minified text output.
  • Preserve user-selected mode in filename, such as payload.formatted.json or payload.minified.json.
  • Show output byte size before download.
  • Include tests for valid JSON, invalid JSON, empty output, and imported files.

Acceptance criteria:

  • Users can download formatted JSON output directly.
  • Download is disabled for empty or invalid output.
  • File contents exactly match visible output.
  • Works for manual input and imported files.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions