@sf-agentscript/monaco
v2.2.16
Published
Monaco Editor integration for AgentScript with tree-sitter syntax highlighting
Readme
@agentscript/monaco
Monaco Editor integration for AgentScript. Registers the AgentScript language, provides syntax highlighting, hover information, and schema resolution for use in browser-based editors.
Overview
This package wires up AgentScript language support for the Monaco Editor. It runs the parser in a Web Worker and provides real-time syntax highlighting, hover tooltips, and theme configuration.
Installation
pnpm add @agentscript/monaco monaco-editormonaco-editor is a peer dependency.
Usage
import { registerAgentScriptLanguage } from '@agentscript/monaco';
// Register the language with your Monaco editor instance
registerAgentScriptLanguage(monaco);Features
- Language registration for
.agentfiles - Syntax highlighting via tree-sitter queries
- Hover provider with type information
- Dark and light theme support
- Parser runs in a Web Worker (non-blocking)
- Schema-aware completions
Scripts
pnpm build # Build (via Vite)
pnpm typecheck # Type-checkLicense
MIT
