Last active
May 5, 2025 10:41
-
-
Save hannafyllingen/f65f955670bea687da86e16681f213c2 to your computer and use it in GitHub Desktop.
Index html for api utvikling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Random CAT</title> | |
| <style> | |
| body { | |
| display: flex; | |
| justify-content: center; | |
| align-items: center; | |
| height: 100vh; | |
| margin: 0; | |
| background-color: #f4f4f4; | |
| text-align: center; | |
| } | |
| h1 { | |
| font-size: 2rem; | |
| color: #333; | |
| } | |
| button { | |
| background-color: blue; | |
| color: white; | |
| border: none; | |
| padding: 12px 24px; | |
| font-size: 16px; | |
| font-weight: bold; | |
| border-radius: 8px; | |
| box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); | |
| transition: all 0.3s ease; | |
| cursor: pointer; | |
| } | |
| button:hover { | |
| background-color: darkblue; | |
| } | |
| #cat_container { | |
| margin-top: 20px; | |
| } | |
| </style> | |
| </head> | |
| <body> | |
| <div> | |
| <h1>Random Cat</h1> | |
| <button onclick="fetchRandomImage()">Trykk meg</button> | |
| <section id="cat_container"></section> | |
| </div> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment