Skip to content

Custom component DX friction points from integration testing #825

@zeroasterisk

Description

@zeroasterisk

Context

While building the custom components guide (PR #824) and integrating YouTube/Maps/Charts into rizzcharts, I documented several friction points. Full friction log: docs/guides/friction-log-custom-components.md in PR #824.

P2 Items

1. Unknown component names silently fail

When the agent generates { "component": "YouTub" } (typo), the renderer silently renders nothing. No console warning, no fallback.

Suggestion: Log a warning and render a placeholder (e.g., "Unknown component: YouTub") in dev mode.

2. Catalog registration boilerplate

The inputBinding() pattern requires knowing @angular/core internals. Each catalog entry needs ~5 lines of binding code per component.

Suggestion: Consider a decorator-based approach:

@A2UIComponent({ name: 'YouTube' })
export class YouTube extends DynamicComponent<Types.CustomNode> {
  @A2UIInput() videoId: string;
}

3. No shared catalog schema

Client and agent must independently define component names/properties. No way to auto-generate agent prompts from client catalog.

Suggestion: A catalog.json schema file consumed by both sides.

P3 Items

  1. resolvePrimitive() lacks JSDoc documentation
  2. No guidance on DI patterns in DynamicComponent subclasses
  3. Theme token consumption in custom components undocumented

Related

Metadata

Metadata

Labels

Type

No type

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions