techthoughts2
11/13/2018 - 10:40 PM

Quickly create JSON structure in PowerShell

Simple method for rapidly creating a JSON structure using PowerShell syntax. ClipboardText helps to get it into the clipboard.

#install-module ClipboardText
#super fast PS way to create quick JSON
ConvertTo-Json -Compress -InputObject @{
    JsonItem1 = "I Am Item1 content"
    JsonItem2 = "I Am Item2 content"
    JsonItem3 = "I Am Item3 content"
} | Set-ClipboardText