T
T
tugo2021-03-22 13:26:10
JSON
tugo, 2021-03-22 13:26:10

Is there a JSON beautifier with separate rules for specific keys?

I want a JSON formatter that, if it encounters a certain key, will format it in the given way.
Those. not this way:

{
    "points": [
        {
            "x": 10,
            "y": 0
        },
        {
            "x": 80,
            "y": 10
        },
        {
            "x": 90,
            "y": 20
        },
        {
            "x": 15,
            "y": 0
        }
    ]
}


Specifically, for the points key

{
    "points": [
        {"x": 10,"y": 0},
        {"x": 80,"y": 10},
        {"x": 90,"y": 20},
        {"x": 15,"y": 0}
    ]
}


If possible, in the form of a js or C/C++ library.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question