This commit is contained in:
Karan
2021-11-25 20:25:10 +05:30
parent 67969b4bce
commit 65c4b167af
8 changed files with 122 additions and 1 deletions
+18
View File
@@ -0,0 +1,18 @@
[
{
"name": "Learn JavaScript",
"status" : true
},
{
"name": "Try JSON",
"status" : false
}
]
const url = "list.json";
fetch(url).then(rep => rep.json())
.then((data) => {
data.forEach((el) => {
console.log(`${el.name} = ${el.status}`);
});
})