-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
63 lines (56 loc) · 1.78 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>GitHub Pages with Node.js Backend</title>
<style>
body {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
margin: 0;
font-family: Arial, sans-serif;
text-align: center;
background-color: #f0f0f0;
}
h1 {
margin-bottom: 20px;
font-size: 2em;
color: #333;
}
p {
font-size: 1.2em;
color: #666;
}
</style>
</head>
<body>
<!-- <h1>Data from Backend</h1>
<p id="message">Loading...</p>
<p id="vercelCheck">Running on: Loading...</p>
<p id="deploymentURL">Deployment URL: Loading...</p> -->
<h1>Carbon Mapping Data</h1>
<h2>A site for finding the largest sources of carbon emissions in your area. </h2>
<h3>Washington State</h3>
<ul>
<a href="/testlocation.html">Test Location</a>
</ul>
<script>
fetch('https://bc-hacks2024.vercel.app/api/data')
.then(response => response.json())
.then(data => {
document.getElementById('message').innerText = data.message;
document.getElementById('deploymentURL').innerText = data.envURL
vercelCheck = data.envProcess;
});
if(vercelCheck == 1) {
var currentText = vercelCheck.innerText;
document.getElementById('vercelCheck').innerText = currentText.replace("Loading...","Vercel is running!");
}
</script>
<script src="testingapi.js"></script>
</body>
</html>