hashicorp / hashicorp/consul

JSON is displayed as a single line in KV editor

Open
#10,318 4 comments 2 reactions 0 assignees View on GitHub
theme/ui type/enhancement
Dominant language
Go
Stars
30.1k
Forks
4.6k
Avg merge
1d 18h
Merged PRs (30d)
39

Description

**Old UI or New UI**
Consul 1.5.3 using new UI

**Describe the problem you're having**
Imported JSON configuration is displayed as a single line in the code editor making it very hard to read the configuration. Especially when it comes to bigger larger amounts of configuration.

![example image](https://i.imgur.com/Hpsyf6i.png)

**Describe the solution you'd like**
Either an option to format the config in the UI or automatic formatting when the page is opened. The formatting should display the JSON over multiple lines as shown in the image below.

![Expected output](https://i.imgur.com/cgEEobf.png)

Contributor guide

Open the contributing guide

Research direction

Start with the Consul new UI KV editor and reproduce the imported JSON example described in the issue. Trace where the editor receives and displays the configuration; done means the JSON is shown across multiple lines in the editor, matching the expected formatting shown in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
json
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.