How to Convert HTML to JSON in PowerShell
To convert HTML to JSON in PowerShell, pull the data out of the HTML into objects first, then pipe the objects to ConvertTo-Json. For a clean table, the quickest way is to cast the HTML to [xml]: Real web pages are rarely clean enough for that. Below I cover the [xml] route, why it breaks … Read more