Skip to main content

AgentPlaygroundLite

A lighter version of AgentPlayground without chat functionality.

Import

import { AgentPlaygroundLite } from "@open-resource-discovery/a2a-editor/lite";
import "@open-resource-discovery/a2a-editor/styles";

Usage

function App() {
return (
<div style={{ height: "100vh" }}>
<AgentPlaygroundLite
onAgentCardChange={(json, parsed) => {
// Save to backend
}}
/>
</div>
);
}

Props

PropTypeDefaultDescription
initialAgentCardstring-Initial agent card JSON string
initialAgentUrlstring-Initial agent URL
showSettingsbooleantrueShow the settings panel
readOnlybooleanfalseMake the editor read-only
defaultTab"overview""overview"Default tab to show
onAgentCardChange(json: string, parsed: AgentCard | null) => void-Callback when agent card changes
onConnect(url: string, card: AgentCard) => void-Callback when connected to agent
classNamestring-Additional CSS class

When to Use

Use AgentPlaygroundLite when:

  • You need the Monaco editor but don't need chat functionality
  • You want a smaller bundle size
  • You're building an editor-only experience

Bundle Size

Entry point: ~4.6 kB (gzip: ~1.5 kB)

Note: Monaco editor is loaded as a shared chunk, so the total loaded size will be larger.