-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrandom.js
More file actions
69 lines (56 loc) · 1.49 KB
/
random.js
File metadata and controls
69 lines (56 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
import {nav,display1} from './navbar.js';
let navbar=nav();
document.getElementById("main").innerHTML=navbar;
let un=JSON.parse(localStorage.getItem("showuser"));
document.getElementById("username").innerText=un.Name;
let mai=document.querySelector("#mai");
async function getAnd(){
try {
let url="https://www.themealdb.com/api/json/v1/1/random.php";
let res= await fetch(url);
let data=await res.json();
display1(data,mai);
} catch (error) {
}
}
getAnd();
async function getAn(){
try {
let url="https://www.themealdb.com/api/json/v1/1/random.php";
let res= await fetch(url);
let data=await res.json();
display1(data,mai);
} catch (error) {
}
}
getAn();
async function getA(){
try {
let url="https://www.themealdb.com/api/json/v1/1/random.php";
let res= await fetch(url);
let data=await res.json();
display1(data,mai);
} catch (error) {
}
}
getA();
async function getAnda(){
try {
let url="https://www.themealdb.com/api/json/v1/1/random.php";
let res= await fetch(url);
let data=await res.json();
display1(data,mai);
} catch (error) {
}
}
getAnda();
async function getAndo(){
try {
let url="https://www.themealdb.com/api/json/v1/1/random.php";
let res= await fetch(url);
let data=await res.json();
display1(data,mai);
} catch (error) {
}
}
getAndo();