Skip to main content
Glama
svg-sprite.tsx630 B
export type SvgSpriteProps = React.SVGProps<SVGSVGElement> & { id: string; size?: number; }; export function SvgSprite({ id, ...props }: SvgSpriteProps) { const height = getDimension(props, "height"); const width = getDimension(props, "width"); return ( <svg {...props} width={width} height={height}> <use href={`/sprite.svg#${id}`} /> </svg> ); } function getDimension( props: Omit<SvgSpriteProps, "id">, dimension: "width" | "height" ) { const defaultValue = 16; if (props[dimension]) { return props[dimension]; } if (props.size) { return props.size; } return defaultValue; }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/metacode0602/open-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server