An open API service indexing awesome lists of open source software.

https://github.com/crovitche-1623/razoar

Clean and optimize DXF files in the browser — dedup, merge colinear segments, remove overlaps
https://github.com/crovitche-1623/razoar

docker-compose dxf rs rust saas ts typescript wasm

Last synced: 3 months ago
JSON representation

Clean and optimize DXF files in the browser — dedup, merge colinear segments, remove overlaps

Awesome Lists containing this project

README

          

# Razoar

[![CI](https://github.com/Crovitche-1623/Razoar/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/Crovitche-1623/Razoar/actions/workflows/ci.yml)
[![CD](https://github.com/Crovitche-1623/Razoar/actions/workflows/cd.yml/badge.svg)](https://github.com/Crovitche-1623/Razoar/actions/workflows/cd.yml)
[![Version](https://img.shields.io/github/v/release/Crovitche-1623/Razoar)](https://github.com/Crovitche-1623/Razoar/releases/latest)
[![Rust Coverage](https://codecov.io/gh/Crovitche-1623/Razoar/graph/badge.svg?flag=rust&token=0AMU9WG3UL)](https://codecov.io/gh/Crovitche-1623/Razoar)
[![License](https://img.shields.io/badge/license-proprietary-red)](LICENSE)
[![Website](https://img.shields.io/badge/website-razoar.ch-blue)](https://razoar.ch)

**DXF Cleaner** — clean and optimize DXF (Drawing Exchange Format) files with real-time preview.

Core cleaning algorithms run in **Rust/WebAssembly** for near-native performance directly in the browser.

## Features

- **Duplicate removal** — detect and remove exact, reversed, and near-duplicate segments
- **Micro-segment removal** — eliminate segments below a configurable length threshold
- **Collinear merging** — merge touching collinear segments into single lines
- **Overlap removal** — remove shorter segments fully contained in longer collinear ones
- **Preserved export** — non-LINE entities (CIRCLE, ARC, LWPOLYLINE, etc.) are preserved verbatim
- **Real-time preview** — instant visual feedback when adjusting cleaning parameters

## Tech Stack

| Layer | Technology |
| --------------- | --------------------------------------------- |
| Frontend | React 18, TypeScript, Tailwind CSS v4 |
| Build | Vite 6 |
| Core algorithms | Rust (edition 2021) → WebAssembly (wasm-pack) |
| Auth | Google OAuth via Cloudflare Pages Functions |
| Payments | Stripe (freemium model) |
| Hosting | Cloudflare Pages + Workers (KV) |

## Prerequisites

- **Docker** (20+) — all tools (Node 22, Rust stable, wasm-pack, Playwright) run inside containers.

## Development

```bash
# Install dependencies
docker compose run --rm dev npm install

# Build WASM (required before first run)
docker compose run --rm dev npm run build:wasm

# Start dev server (http://localhost:5173)
docker compose up -d dev

# Run full CI pipeline
docker compose run --rm dev sh -c "npm run rust:fmt:check && npm run rust:lint && npm run rust:test && npm run format:check && npm run lint && npm run typecheck && npm test && npm run build"
```

## License

Proprietary — All rights reserved. See [LICENSE](LICENSE) for details.