सही घटक अनुबंध खोजें
घटक खोजें। उसका सटीक 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);
}