BrandKit
A Go toolkit for processing brand icons — analyzing, verifying, and converting SVG files. Use it as a CLI tool or as a library in your own Go programs.
Features
- SVG Color Conversion — Convert icons to white, any hex color, or preserve original colors
- Background Removal — Remove solid backgrounds while preserving transparency
- Geometry Analysis — Analyze centering, padding, and viewBox optimization
- Pure Vector Verification — Detect embedded raster data, base64, and data URIs
- Security Scanning — Detect XSS threats, malicious scripts, and unsafe elements
- Sanitization — Remove security threats while preserving valid SVG content
- Brand Asset Library — 55+ brand icons with standardized variants
Quick Start
CLI Installation
Library Installation
Basic Usage
# Create white icon on transparent background
brandkit white icon_orig.svg -o icon_white.svg
# Security scan SVG files
brandkit security-scan brands/
# Verify pure vector (no embedded raster)
brandkit verify icon.svg
Documentation
- Getting Started — Installation and first steps
- CLI Reference — Complete command reference
- Library API — Go package documentation
- Security Guide — Threat detection and sanitization
- Brand Assets — Available brand icons
License
MIT License — See LICENSE for details.