정확한 컴포넌트 계약 찾기

구성 요소를 찾고 정확한 API를 읽으세요.

공개 카탈로그, 구조화된 API 인덱스, 분할 참조 및 MCP 검색을 통해 컴포넌트 속성, 이벤트, 슬롯, 피어 및 마이그레이션 가이드를 확인할 수 있습니다. 이를 통해 코딩 에이전트는 마크업을 작성하기 전에 좁은 계약을 검사할 수 있습니다.

예제

컴포넌트를 검색한 다음 정확한 API를 확인하세요.

const origin = 'https://www.lyra-ui.com/api/v1/components';
const search = await fetch(origin + '/search?q=combobox');
if (!search.ok) throw new Error('Component search failed');
const { matches } = await search.json();
const tag = matches[0]?.tag;
if (tag) {
  const response = await fetch(origin + '/' + encodeURIComponent(tag));
  if (!response.ok) throw new Error('Component reference failed');
  const reference = await response.json();
  console.log(reference.markdown);
}

컴포넌트 둘러보기 · 가이드 읽기(영어)