ferrovia is a SVGO-compatible SVG optimizer written in Rust.
Project homepage: oss.sebastian-software.com
The current focus is byte-level behavioral parity with svgo@4.0.1, verified through differential tests and vendored fixture coverage. The project contains:
ferrovia-core: the Rust optimizer libraryferrovia-cli: the native CLIferrovia-napiandpackages/node: the Node.js bindings
This project is under active development.
- Differential verification against
svgo@4.0.1is part of the normal workflow. - The port is intentionally incremental: plugins are implemented in small verified waves.
- The implementation is not yet feature-complete relative to upstream SVGO.
- Preserve SVGO-compatible config and plugin semantics where practical.
- Keep the Rust core CPU- and memory-conscious.
- Verify behavior against upstream fixtures and a pinned Node-based oracle.
crates/ferrovia-core
crates/ferrovia-cli
crates/ferrovia-napi
packages/node
docs/adr
tests
Prerequisites:
- Rust toolchain
- Node.js
- pnpm
Install dependencies:
pnpm installRun the main verification steps:
cargo test
cargo clippy --all-targets --all-features -- -D warnings
bash ./scripts/check-regressions.shBuild the Node addon:
pnpm build:napi- Architecture decisions live in
docs/adr/. - Ongoing compatibility and regression checks live under
tests/andscripts/.
See CONTRIBUTING.md.
See SECURITY.md.
MIT. See LICENSE.