UNPKG

astro-svgs

Version:

A compact solution for SVG sprites in Astro projects. It automates symbol ID management, supports hot reloading, and generates optimized SVG sprites with minimal setup—ideal for seamless SVG icon integration.

25 lines (22 loc) 666 B
import { AstroIntegration } from 'astro'; declare const name = "astro-svgs"; interface SVGsOptions { /** * Specify the folder where the svg file is located. * @default "src/svgs" */ input?: string | string[]; /** * Compression level of `sprite.svg` file. * @default * isDev ? 'beautify' : 'high', */ compress?: Precision; } type Precision = "beautify" | "low" | "medium" | "high"; declare class Error1 extends Error { hint?: string; constructor(message: string); } declare function svgs(options?: SVGsOptions): AstroIntegration; export { Error1, type Precision, type SVGsOptions, svgs as default, name };