sfn-diagram 1.9.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -23,6 +23,8 @@ Generate diagrams from AWS Step Functions ASL (Amazon States Language) definitio
23
23
  npm install sfn-diagram
24
24
  ```
25
25
 
26
+ Requires Node >= 22.12.0 on Node; the package is ES modules only, and `require()` works there. Upgrading from 1.x? See [Migrating to 2.0](https://sfn.yusufaf.dev/upgrading-to-v2/).
27
+
26
28
  The core package pulls in **no browser engine or native rasterizer** — SVG and Mermaid generation stay lightweight. PNG export uses `@resvg/resvg-js`, a native, browser-free renderer, provided by an optional peer dependency. Install it only if you use `sfn-diagram/png`:
27
29
 
28
30
  ```bash
@@ -119,7 +121,7 @@ from a bad definition. See
119
121
  - **Modern ASL**: Variables (`Assign`) shown per state, and Distributed Map rendered distinctly from an inline Map — including its `MaxConcurrency`, `ItemReader` source, and `ResultWriter` sink
120
122
  - **Visual Diffing**: Compare two definitions and highlight added / modified / removed states — drives the PR-preview GitHub Action
121
123
  - **Linting**: `lintAsl()` returns every structural and semantic finding at once (unreachable states, dangling transitions, `End` with `Next`, JSONPath/JSONata field mixing, …); `sfn-diagram --check` fails CI on errors
122
- - **Execution Overlays**: Paint a real execution's history onto the diagram — succeeded/failed/caught/not-reached states, the taken path, and per-state duration & retry counts. From a saved history file or live from an execution ARN, and `--follow` keeps re-rendering until the run finishes; with `--format html` it can be painted onto a `--diff` in the same viewer
124
+ - **Execution Overlays**: Paint a real execution's history onto the diagram — succeeded/failed/caught/aborted/not-reached states, the taken path, and per-state duration & retry counts. From a saved history file or live from an execution ARN, and `--follow` keeps re-rendering until the run finishes; with `--format html` it can be painted onto a `--diff` in the same viewer
123
125
  - **Customizable Themes**: AWS light/dark themes, an `auto` theme that follows the system colour scheme, plus custom theme support
124
126
  - **Flexible Layouts**: Top-bottom, left-right, right-left, bottom-top
125
127
  - **Type-Safe**: Full TypeScript support with comprehensive type definitions
@@ -157,6 +159,8 @@ Full documentation lives at **[sfn.yusufaf.dev](https://sfn.yusufaf.dev)**.
157
159
  - [Examples](https://sfn.yusufaf.dev/guides/examples/) — complete worked examples
158
160
  - [Use with your framework](https://sfn.yusufaf.dev/guides/frameworks/) — Next.js, Remix, SvelteKit, Astro
159
161
  - [API reference](https://sfn.yusufaf.dev/reference/) — generated from source, always current
162
+ - [Compatibility policy](https://sfn.yusufaf.dev/compatibility/) — what each version number promises
163
+ - [Migrating to 2.0](https://sfn.yusufaf.dev/upgrading-to-v2/) — upgrading from 1.x, with before-and-after code for every breaking change
160
164
 
161
165
  Working with an AI coding agent? The docs are published as [llms.txt](https://sfn.yusufaf.dev/llms.txt), and every page is available as raw Markdown by appending `.md` to its URL.
162
166
 
@@ -173,7 +177,7 @@ Working with an AI coding agent? The docs are published as [llms.txt](https://sf
173
177
 
174
178
  ## Runtime support
175
179
 
176
- Core (`sfn-diagram`) is platform-agnostic — it runs in Node, the browser, and edge runtimes. Only `sfn-diagram/png` and the CLI are Node-only. See [runtime support](https://sfn.yusufaf.dev/guides/runtimes/).
180
+ Core (`sfn-diagram`) is platform-agnostic — it runs in Node, the browser, and edge runtimes. Only `sfn-diagram/png` and the CLI are Node-only. On Node it needs Node >= 22.12.0. See [runtime support](https://sfn.yusufaf.dev/guides/runtimes/).
177
181
 
178
182
  ## Contributing
179
183