{"library":"svg-to-ts","type":"library","category":null,"description":"svg-to-ts is a build tool that converts SVG icons into TypeScript or TSX files, facilitating the creation of tree-shakable icon libraries. It processes SVG files, applies optional SVGO optimization, and generates various output formats: a single TypeScript file exporting a constants object, multiple individual named constant exports, or separate files for each icon, optimized for lazy loading. It also automatically generates corresponding TypeScript types and interfaces for the icon sets. The current stable version is 12.0.0. The project maintains a consistent release cadence, often introducing major versions annually driven by updates to underlying tools like SVGO or advancements in TypeScript language features. Its key differentiators include robust SVGO integration for automatic optimization, broad support for Angular, React, and vanilla TypeScript/JavaScript environments, and the flexibility to produce diverse output structures tailored to different application architectures and lazy-loading strategies. This makes it a versatile solution for authors of component and icon libraries, as well as single-page application developers.","language":"javascript","status":"active","version":"12.0.0","tags":["javascript","SVG","TypeScript","Icons","Build-tool"],"last_verified":"Wed May 27","install":[{"cmd":"npm install svg-to-ts","imports":["import { GeneratedIconEnum } from './path/to/generated-icons';","import { ICON_NAME } from './path/to/generated-icons';","import { IndividualIconComponent } from './path/to/icon-name.mjs';"]},{"cmd":"yarn add svg-to-ts","imports":[]},{"cmd":"pnpm add svg-to-ts","imports":[]}],"homepage":null,"github":"https://github.com/kreuzerk/svg-to-ts","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/svg-to-ts","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/svg-to-ts/compatibility"}}