Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import { githubNotifications } from "https://esm.town/v/pomdtr/githubNotifications";
export async function sunbeamGithubNotifications() {
const notifications = await githubNotifications();
return {
type: "list",
title: "Github Notifications",
items: notifications.map((notification) => ({
title: notification.subject.title,
accessories: [notification.repository.full_name],
actions: notification.subject.url
? [{ type: "open", target: notification.subject.url }]
: undefined,
})),
};
}
October 23, 2023