This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This is an MCP (Model Context Protocol) server that provides access to Livewire Flux Components documentation from https://fluxui.dev/docs/. The server runs locally and can be used with npx to fetch documentation on demand.
npm install- Install dependenciesnpm start- Start the MCP servernpm run dev- Start the server with file watching for developmentnpx .- Run the server directly with npx
The project consists of a single main file (index.js) that implements:
- FluxDocumentationServer class: Main server implementation using MCP SDK
- Two MCP tools:
fetch_flux_docs: Fetches documentation for specific components or searches contentlist_flux_components: Lists all available Flux components from the documentation site
- Web scraping: Uses cheerio to parse HTML content from fluxui.dev
- Content extraction: Intelligently extracts documentation content from the website
-
fetch_flux_docs:
- Optional
componentparameter for specific component docs - Optional
searchparameter to filter content - Returns formatted documentation text
- Optional
-
list_flux_components:
- No parameters required
- Returns list of available components with their paths
@modelcontextprotocol/sdk: Core MCP functionalitycheerio: HTML parsing and content extractionnode-fetch: HTTP requests to documentation site