diff options
| author | Josh Kingsley <josh@joshkingsley.me> | 2025-10-29 01:54:37 +0200 |
|---|---|---|
| committer | Josh Kingsley <josh@joshkingsley.me> | 2025-10-29 01:54:37 +0200 |
| commit | 986e65f9ab7122995ae1d647df23d817cecf6816 (patch) | |
| tree | 39d4f77c6a6565b59522a5a77e2f550334472713 /web/src/components/grid/excursion.ts | |
| parent | 95069f13d908bfd3c0f3b33f8fad7d8464fd192e (diff) | |
refactor(web): improve state management
Diffstat (limited to 'web/src/components/grid/excursion.ts')
| -rw-r--r-- | web/src/components/grid/excursion.ts | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/web/src/components/grid/excursion.ts b/web/src/components/grid/excursion.ts new file mode 100644 index 0000000..7752df1 --- /dev/null +++ b/web/src/components/grid/excursion.ts @@ -0,0 +1,8 @@ +export default function excursion( + ctx: CanvasRenderingContext2D, + f: () => void, +) { + ctx.save(); + f(); + ctx.restore(); +} |
