(c: {
type: string;
slug?: string | null;
name: string;
content?: string | null;
metadata?: Record<string, unknown> | null;
})
| 27 | // description, or sort_order must not trigger a rescan. MCP install links and |
| 28 | // configs can live in metadata, so compare the metadata that will be saved. |
| 29 | function fingerprintComponent(c: { |
| 30 | type: string; |
| 31 | slug?: string | null; |
| 32 | name: string; |
| 33 | content?: string | null; |
| 34 | metadata?: Record<string, unknown> | null; |
| 35 | }): string { |
| 36 | const slug = resolveComponentSlug(c); |
| 37 | return JSON.stringify({ |
| 38 | type: c.type, |
| 39 | slug, |
| 40 | content: c.content ?? "", |
| 41 | metadata: c.metadata ?? {}, |
| 42 | }); |
| 43 | } |
| 44 | |
| 45 | function resolveComponentMetadata( |
| 46 | comp: ComponentInput, |
no test coverage detected