First commit

This commit is contained in:
2025-09-10 14:42:57 -04:00
commit 1d12903e4e
65 changed files with 3587 additions and 0 deletions

34
Prep 8/load.html Executable file
View File

@@ -0,0 +1,34 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Nicholas Tamassia - Prep 8 - Load</title>
<style>
/* YOUR STYLE HERE */
</style>
</head>
<body>
<div id="name-display"></div>
<div id="favorite-display"></div>
<div id="quotes-display"></div>
<script>
const nameDisplay = document.getElementById('name-display')
const favoriteDisplay = document.getElementById('favorite-display')
const quotesDisplay = document.getElementById('quotes-display')
nameDisplay.textContent = localStorage.getItem('fullname')
favoriteDisplay.textContent = Number.parseFloat(localStorage.getItem('favnumber')) + 5
JSON.parse(localStorage.getItem('quotes')).forEach((quote) => {
const listItem = document.createElement('li')
listItem.textContent = quote
quotesDisplay.appendChild(listItem)
});
</script>
</body>
</html>

33
Prep 8/save.html Executable file
View File

@@ -0,0 +1,33 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Nicholas Tamassia - Prep 8 - Save</title>
<style>
/* YOUR STYLE HERE */
</style>
</head>
<body>
Data saved!
<script>
const items = {
'fullname': 'Nicholas Tamassia',
'favnumber': '28', // It's a Perfect Number! Literally.
'quotes': [
"Savior, conqueror, hero, villain. You are all things, Revan... and yet you are nothing. In the end, you belong to neither the light nor the darkness. You will forever stand alone.",
"Do you know the difference between an error and a mistake? Anyone can make an error. But that error doesn't become a mistake until you refuse to correct it.",
"It is said that one should keep one's allies within view, and one's enemies within reach"
]
}
for (const [key, value] of Object.entries(items)) {
localStorage.setItem(key, typeof value === "string" ? value : JSON.stringify(value))
}
</script>
</body>
</html>