Skip to content

Instantly share code, notes, and snippets.

@paulonteri
Created July 26, 2021 18:40
Show Gist options
  • Save paulonteri/f1ebd76e9fb67f30f5d5afe895274361 to your computer and use it in GitHub Desktop.
Save paulonteri/f1ebd76e9fb67f30f5d5afe895274361 to your computer and use it in GitHub Desktop.
const jsonObj = {"doorsWindows":[{'ID':"A","style":"apple"},{'ID':"B","style":"apple"},{'ID':"C","style":"apple"}]}
const doorsWindowsIds = []
for (var i = 0; i < jsonObj.doorsWindows.length; i++) {
let doorWindow = jsonObj.doorsWindows[i];
doorsWindowsIds.push(doorWindow.ID)
}
console.log(doorsWindowsIds)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment