src/pages/now/index.astro 2.7 K raw
1
---
2
export const prerender = false;
3
4
import PageLayout from "@/layouts/Base.astro";
5
import NowUpdates from "@/components/now/NowUpdates.astro";
6
import Weather from "@/components/now/Weather.astro";
7
8
const meta = {
9
	title: "/now",
10
	description: "What I'm up to recently",
11
};
12
13
const STATION = "PQR";
14
const GRID_X = "115";
15
const GRID_Y = "103";
16
const LOCATION = "Portland, OR";
17
18
const forecastRequest = await fetch(
19
	`https://api.weather.gov/gridpoints/${STATION}/${GRID_X},${GRID_Y}/forecast/hourly`,
20
	{
21
		method: "GET",
22
		headers: {
23
			accept: "application/geo+json",
24
			"User-Agent": "(stevedylan.dev, contact@stevedylan.dev)",
25
		},
26
	},
27
);
28
const forecast = await forecastRequest.json();
29
const { shortForecast, temperature } = forecast.properties.periods[0];
30
const weather = `${shortForecast},${temperature},${LOCATION}`;
31
---
32
33
<PageLayout meta={meta}>
34
  <div class="space-y-6">
35
    <h1 class="title">/now</h1>
36
    <div class="flex text-sm text-zinc-400 items-center gap-x-3 gap-y-1 flex-wrap">
37
      <Weather weather={weather} />
38
    </div>
39
    <p>What I'm up to recently</p>
40
    <ul class="list-disc pl-4 space-y-4">
41
      <li>Working as Senior Solutions Engineer at Stablecore</li>
42
      <li>
43
        Building personal software with <a
44
          class="style-link"
45
          target="_blank"
46
          rel="noreferrer"
47
          href="https://andromeda.build">Andromeda</a>
48
      </li>
49
      <li>Updating this site with fun stuff</li>
50
      <li>Learning how to build HTTP from TCP in Go</li>
51
      <li>Spending some time in Oregon</li>
52
      <li>Watching birds</li>
53
      <li>Reading The Count of Monte Cristo</li>
54
    </ul>
55
    <p class="text-zinc-400">Last updated: Jun 21st, 2026</p>
56
    <div class="flex flex-row justify-between items-center w-full pt-12 pb-6">
57
      <h2 class="title">Updates</h2>
58
      <div class="flex gap-2 items-center">
59
        <a
60
          class="inline-block p-2 sm:hover:text-link"
61
          href="https://posts.stevedylan.dev/feed.xml"
62
          target="_blank"
63
          rel="noopener noreferrer"
64
        >
65
          <svg
66
            xmlns="http://www.w3.org/2000/svg"
67
            class="h-6 w-6"
68
            viewBox="0 0 24 24"
69
            stroke-width="1.5"
70
            stroke="currentColor"
71
            fill="none"
72
            stroke-linecap="round"
73
            stroke-linejoin="round"
74
          >
75
            <g
76
              fill="none"
77
              stroke="currentColor"
78
              stroke-linecap="round"
79
              stroke-linejoin="round"
80
              stroke-width="2"
81
              ><path d="M4 11a9 9 0 0 1 9 9M4 4a16 16 0 0 1 16 16"
82
              ></path><circle cx="5" cy="19" r="1"></circle></g
83
            >
84
          </svg>
85
          <span class="sr-only">RSS</span>
86
        </a>
87
      </div>
88
    </div>
89
    <NowUpdates />
90
  </div>
91
</PageLayout>