-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
48 lines (38 loc) · 1.64 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
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Bootstrap CSS -->
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-giJF6kkoqNQ00vy+HMDP7azOuL0xtbfIcaT9wjKHr8RbDVddVHyTfAAsrekwKmP1" crossorigin="anonymous">
<title>💿 Spotify CoverGen</title>
</head>
<body>
<div class="container">
<div class="row justify-content-center text-center">
<div class="col-5">
<h1>💿 Spotify CoverGen</h1>
<p>Create stylish playlists for your Spotify Playlists 💅</p>
<button type="submit" class="btn btn-primary" id="sign-in-button">Sign In</button>
</div>
</div>
</div>
<!-- Optional JavaScript; choose one of the two! -->
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"
integrity="sha384-ygbV9kiqUc6oa4msXn9868pTtWMgiQaeYH7/t7LECLbyPA2x65Kgf80OJFdroafW" crossorigin="anonymous">
</script>
<script>
const SPOTIFY_CLIENT_ID = 'c77a7c123cfe4f7893a5e1ff973396da';
const signInButton = document.querySelector('#sign-in-button');
signInButton.addEventListener('click', async () => {
const response = await fetch('https://accounts.spotify.com/authorize', {
response_type: 'token',
redirect_uri: 'https://spotify-covergen.github.io',
});
console.log(response);
});
</script>
</body>
</html>