WIP: A simple cli for daily tangled use cases and AI integration. This is for my personal use right now, but happy if others get mileage from it! :)
7
fork

Configure Feed

Select the types of activity you want to include in your feed.

Define custom IssueRecord interface instead of importing from generated code

- Define IssueRecord interface locally in issues-api.ts
- Based on sh.tangled.repo.issue lexicon schema
- Includes required index signature for AT Protocol compatibility
- Documents lexicon source for reference

- Avoids TypeScript compilation issues with generated lexicon types
- Maintains full type safety while working around codegen limitations

This approach is recommended in src/lexicon/README.md and provides
a stable interface that won't break when lexicons are regenerated.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

+14 -3
+14 -3
src/lib/issues-api.ts
··· 1 - import type { Record as IssueRecord } from '../lexicon/types/sh/tangled/repo/issue.js'; 2 1 import { parseAtUri } from '../utils/at-uri.js'; 3 2 import { requireAuth } from '../utils/auth-helpers.js'; 4 3 import type { TangledApiClient } from './api-client.js'; 5 4 6 - // Re-export the generated issue record type for convenience 7 - export type { IssueRecord }; 5 + /** 6 + * Issue record type based on sh.tangled.repo.issue lexicon 7 + * @see lexicons/sh/tangled/issue/issue.json 8 + */ 9 + export interface IssueRecord { 10 + $type: 'sh.tangled.repo.issue'; 11 + repo: string; 12 + title: string; 13 + body?: string; 14 + createdAt: string; 15 + mentions?: string[]; 16 + references?: string[]; 17 + [key: string]: unknown; 18 + } 8 19 9 20 /** 10 21 * Issue record with metadata