index.js
//Function to generate the Html page
Function to generate the Html page
Function to generate the Html page
function generateHTML(data, color) {
 return `
   <!DOCTYPE html>
   <html lang="en">
      <head>
         <meta charset="UTF-8" />
         <meta name="viewport" content="width=device-width, initial-scale=1.0" />
         <meta http-equiv="X-UA-Compatible" content="ie=edge" />
         <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.8.1/css/all.css"/>
         <link href="https://fonts.googleapis.com/css?family=BioRhyme|Cabin&display=swap" rel="stylesheet">
         <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
         <title>GitHub Profile</title>
         <style>
         .jumbotron {
            padding: 2rem 1rem;
            background-color: black;
            border-radius: 10px;
            color: white;
            margin: 40px;
         }
           .nameColor{
            color:${color}
           } 
          </style>     
    </head>
    <body>
         <div class="jumbotron .container-fluid">
             <h3 class="display-5 nameColor">${data.name}</h3>
             <hr class="my-4">
             <img src=${data.avatar_url} width="200" height="200" alt="user"></img>
             </br></br>
             <p class="lead">Bio: ${data.bio}</p>
             <p class="lead"><a href=${data.html_url}>${data.name}'s GitHub Profile</a></p>
             <p class="lead"><a href=${data.blog}>${data.name}'s Blog</a></p>
             <p class="lead">GitHub Stars: ${data.public_gists}</p>
             <p class="lead">Public Repos: ${data.public_repos}</p>
             <p class="lead">Followers: ${data.followers}</p>
             <p class="lead">Following: ${data.following}</p>
             <p class="lead">Location: ${data.location}</p>
             <hr class="my-4">
          </div> 
    </body>   
   </html> `
}
function generateHTML ( data , color ) { return ` ${ color } ${ data . name } ${ data . avatar_url } ${ data . bio } ${ data . html_url } ${ data . name } ${ data . blog } ${ data . name } ${ data . public_gists } ${ data . public_repos } ${ data . followers } ${ data . following } ${ data . location } ` }
Function to generate the Html page
Function to generate the Html page