Skip to content

Export Results as SARIF

Latest

Choose a tag to compare

@RubenHalman RubenHalman released this 03 Nov 21:36
· 24 commits to main since this release

exportSarif(results: ScanResult[]): string

Generates SARIF output with real file paths and exact line numbers — powered by mapRegion() scanning raw XML via flow.toXMLString().

Supports: both Local files and Browser by leveraging Flow.toXMLString() → accurate lines, no files needed

Example

// Get SARIF output
import { parse, scan, exportSarif } from "@flow-scanner/lightning-flow-scanner-core";
parse("flows/*.xml")
  .then(scan)
  .then(exportSarif)
  .then((sarif) => save("results.sarif", sarif));