This mirrors packages/exporters/README.md directly. See also the generated API reference.
@rekhly/exportersPNG/JPEG/SVG/PDF/CSV/JSON export for Rekhly Visuals.
import { exportCanvasImage, exportSvg, exportPdf, exportCsv } from "@rekhly/exporters";
const png = exportCanvasImage(canvas, { format: "png", scale: 2 });
const pdf = exportPdf(chart.engine.scene.compile(), width, height);
exportCanvasImage — rasterizes a canvas at 1x–16x scale, PNG or JPEG.exportSvg — scene → SVG, works without a GPU.exportPdf — scene → a real single-page PDF 1.4 file: catalog, pages,page, content stream, and a byte-accurate xref table/trailer. Openable in any PDF viewer, not a screenshot wrapped in a header.
exportCsv / exportJson — tabular and raw data export.exportPdf never fakes the object graph — every xref offset must land exactly on its N 0 obj marker (verified in tests).
Got any questions? I'm happy to help with products, licensing, and examples.