worldwide todo list: public todo list of 68 real, sourced problems (planet to street) at /projects/worldwide-todo. worldtodo schema (categories, tasks, change_requests), idempotent seed on deploy, public add/edit/delete requests with Turnstile + salted daily-rotating IP-hash rate limit, owner-only review queue (approve, edit & approve, reject) with live updates over /ws/worldtodo(-owner), JSON API, detail pages with OSM map and history; listed in projects, header, /start and sitemap
Deploy production / deploy (push) Failing after 9s
Deploy production / deploy (push) Failing after 9s
This commit is contained in:
1 parent
0ee981a96b
commit
5e812271e1
58 files changed
+47689
-9
No files matched your search
@@ -7,6 +7,7 @@ import { COURSES } from '#lib/language-learner/courses/index.js';
|
||||
import { gameTrackers } from '#lib/projects.js';
|
||||
import { and, eq, isNull, ne } from 'drizzle-orm';
|
||||
import { getVisibility } from '#lib/server/movies/site.js';
|
||||
import { sitemapSlugs } from '#lib/server/worldtodo/store.js';
|
||||
import type { RequestHandler } from './$types';
|
||||
|
||||
const staticPaths = [
|
||||
@@ -49,6 +50,7 @@ const staticPaths = [
|
||||
'/projects/game-tracker/pokemon',
|
||||
'/projects/game-tracker/osu',
|
||||
'/projects/game-tracker/pokemon/locations',
|
||||
'/projects/worldwide-todo',
|
||||
'/projects/animaldex',
|
||||
'/projects/derby',
|
||||
'/projects/spotify-beatmap-finder',
|
||||
@@ -70,7 +72,7 @@ function escapeXml(value: string): string {
|
||||
}
|
||||
|
||||
export const GET: RequestHandler = async () => {
|
||||
const [articles, lists, books, moviesVisibility] = await Promise.all([
|
||||
const [articles, lists, books, moviesVisibility, worldtodo] = await Promise.all([
|
||||
db
|
||||
.select({ slug: blogArticles.slug, updatedAt: blogArticles.updatedAt })
|
||||
.from(blogArticles)
|
||||
@@ -81,7 +83,8 @@ export const GET: RequestHandler = async () => {
|
||||
.from(bookWorks)
|
||||
// Articles are links to other sites; their pages here are thin.
|
||||
.where(and(ne(bookWorks.kind, 'article'), isNull(bookWorks.archivedAt))),
|
||||
getVisibility()
|
||||
getVisibility(),
|
||||
sitemapSlugs().catch(() => [])
|
||||
]);
|
||||
const entries: { path: string; lastmod?: string }[] = [
|
||||
...staticPaths
|
||||
@@ -96,6 +99,10 @@ export const GET: RequestHandler = async () => {
|
||||
...books.map((book) => ({
|
||||
path: `/trackers/books/${book.id}`,
|
||||
lastmod: book.updatedAt.toISOString()
|
||||
})),
|
||||
...worldtodo.map((task) => ({
|
||||
path: `/projects/worldwide-todo/${encodeURIComponent(task.slug)}`,
|
||||
lastmod: task.updatedAt
|
||||
}))
|
||||
];
|
||||
const body = `<?xml version="1.0" encoding="UTF-8"?>\n<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">\n${entries
|
||||
|
||||
Reference in new issue
Block a user