Skip to content
← Public packages

@kentcdodds/photo-portfolio

A fast, photo-first portfolio site you update by chatting with your agent: galleries, about, contact, and one-step rollback.

FollowFork

Files

routes.ts

20 lines · 682 B · TypeScript
import { packageContext } from 'kody:runtime'
import { form, route } from 'remix/routes'

// Hosted apps live under a mount (/packages/<leaf>). Prefixing the contract
// keeps every href(), redirect, and form action inside it.
export const routes = route(packageContext?.appBasePath ?? '', {
	home: '/',
	galleries: '/galleries',
	gallery: '/galleries/:slug',
	photo: '/galleries/:slug/:photoId',
	about: '/about',
	contact: form('contact'),
	// `.` is a route delimiter, so the file name is captured as width + ext.
	media: '/media/:photoId/:width.:ext',
	sitemap: '/sitemap.xml',
	robots: '/robots.txt',
	preview: '/preview',
	previewExit: '/preview/exit',
	health: '/health',
})