26 lines
771 B
HTML
26 lines
771 B
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<title>Hello Nitro</title>
|
|
<script server:setup>
|
|
const name = "AYOs";
|
|
return { name, greeting: "hey" }; // TODO: this is illegal! figure out a way to build an object in the route intercept
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<a href="/about">About</a>
|
|
<div>
|
|
<hello-world name="{{name}}"></hello-world>
|
|
</div>
|
|
<span>some text: {{greeting}}</span>
|
|
<clickable-text></clickable-text>
|
|
<script>
|
|
const helloWorld = document.querySelector("hello-world");
|
|
setTimeout(() => {
|
|
helloWorld.setAttribute("name", "Nitro");
|
|
}, 2000);
|
|
</script>
|
|
</body>
|
|
</html>
|