-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.js
More file actions
112 lines (99 loc) · 4.7 KB
/
main.js
File metadata and controls
112 lines (99 loc) · 4.7 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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
console.log("JS on");
fetch('https://api.github.com/users/kharrison7')
.then(
function(response) {
if (response.status !== 200) {
console.log('Looks like there was a problem. Status Code: ' +
response.status);
return;
}
// Examine the text in the response
response.json().then(function(data) {
console.log("data: " + data.login);
// This changes values to actual items if API sends null or undefined.
let email_address ='';
if (data.email === null){
email_address = "kharrison7@elon.edu";
}
else{
email_address = data.email;
}
let website ='';
if (data.blog === 'https://kharrison7.github.io/Profile/'){
website = "You Are Here";
}
else{
website = data.blog;
}
{/* <div class="project_example">
<p>More coming soon.</p>
</div> */}
// This makes the items appear on the page.
let markup = `
<div class="your_name">
<h1>${data.name}, Web Developer</h1>
</div>
<div class="box_of_three">
<div class="profile_Image">
<img class="img-circle" src="${data.avatar_url}" alt="profile_pic"/>
</div>
<div class="title1">
<h2>Contact Information</h2>
<p>Name: ${data.name}</p>
<p>Github URL: <a href="${data.html_url}" class="bright">${data.login}</a></p>
<p>Email: ${email_address}</p>
<p>Company: ${data.company}</p>
<p>Website: <a href="${data.blog}" class="bright">${website}</a></p>
</div>
<div class="title2">
<h2>About</h2>
<p>I'm a full stack developer working primarily in JavaScript. I work for the North Carolina League of Municipalities.</p>
<a href="Kevin.Harrison.Resume.pdf">Resume</a>
</div>
</div>
<br>
<hr>
<div class="box_of_projects">
<h2 class="my_projects">My Projects</h2>
<!-- <div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://canigrow.github.io/canigrow-frontend/';" value="Can-I-Grow">
<p>A website to assist budding gardeners.</p>
</div> -->
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='http://www.durhaminternalmedicalassociates.com/';" value="Medical Associates">
<p>A website for a local medical practice hosted using Amazon Web Services.</p>
</div>
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://kharrison7.github.io/memory-game/';" value="Memory Matching">
<p>Play a memory matching tile game.</p>
</div>
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://word-guess-08-31.herokuapp.com';" value="Word Guess">
<p>Play a hangman style word guessing game.</p>
</div>
</div>
<div class="box_of_projects">
<h2 class="white-text">My Projects</h2>
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://tiy-durham-etsy-project.github.io/Etsy-group-project';" value="Etsy Project">
<p>View a recreation of Etsy using React.</p>
</div>
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://kharrison7.github.io/iTunes-Music-Search/';" value="Itunes Music Search">
<p>Search itunes for your favorite music.</p>
</div>
<div class="project_example">
<input type="button" class="search_button" onclick="location.href='https://kharrison7.github.io/week-one-project/';" value="Bent Creek Ceramics">
<p>View a mockup website template.</p>
</div>
</div>
<div class="box_of_links">
<div>
<a href="https://www.linkedin.com/in/kevin-harrison-00461248/"><img class="linked_in" src="images/icons/linkedinimg.png"></a>
<a href="https://www.momentumlearn.com/"><img class="linked_in" src="images/icons/tiy.jpg"></a>
</div>
</div>
`
document.body.innerHTML = markup;
});
})