I have similar JSONs like this and I want parse these JSONs with Powershell.
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"newProjectRoot": "projects",
"projects": {
"my-app": {
"projectType": "application",
"schematics": {
"@schematics/angular:component": {
"style": "scss"
}....
I can do it with command $angularJsonPSO.projects."my-app".projectType
for every single JSON but I want some generic command for all these JSONs. Something like "...projects.*.projectType...". How is possible do it this way ?
$angularJson = Get-Content -Raw -Path "./angular.json"
$angularJsonPSO = $angularJson | ConvertFrom-Json -Depth 10
$projectName = $angularJsonPSO.projects."my-app".projectType
Thank you very much for any answer.