Overcast » September 23, 2015

Daily Archives: September 23, 2015

Azure Resource Manager

Using JSON Edit to edit my ARM Templates

Published by:

I have just seen a Twitter about JSONEdit and have decided to give it a try. It can be a bit challenging to edit JSON using Visual Studio. Although you can see the tree, you can really interact with with, like copying and editing content. My expectations are that I will be able to do that with JSONEdit.

You can download it from here: http://tomeko.net/software/JSONedit/

Installation, well, there was no installation, actually. When I ran it, I’ve got this very screamy page:


I believe I can trust it, so, let’s run it anyways.

And there you have it. Let’s try opening some files. I have the files I have used for my ARM previous articles. On the first try, I had this error:


And it really seems that there is something funny there:


Even removing the characters, it won’t think this is a JSON file when asking to reformat the code:



Let’s try editing it with VS and then paste it directly to JSONEdit. Once I did that, I could easily see the tree:


The nice thing about the tree here is that you can edit the content:


You can also order the nodes and even better, copy and paste (as child or sibling):


Once you have it changed, you can paste it back to Visual Studio, for testing and deployment.

In summary, it seems like a nice tool to have, if you want to make sure you are replicating whole sessions or wants to better visualize some variables and resources. It seems Microsoft stored more data in the JSON files, which are not well understood by JSONEdit, but still good to have around when you are editing ARM Templates.


Hope this helps!