Skip to content

Commit 4739e86

Browse files
authored
Merge pull request #276 from airframesio/devin/1755138151-node-support-matrix
chore(node): support Node >=18; test 18/20/22/24; dev on Node 24 types
2 parents 121794c + 6c8bd4f commit 4739e86

File tree

7 files changed

+34
-13
lines changed

7 files changed

+34
-13
lines changed

.github/workflows/yarn-test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ jobs:
1616

1717
strategy:
1818
matrix:
19-
# build against all active LTS and latest node
20-
node-version: [18.x, 20.x, latest]
19+
# build against all active LTS and current stable node
20+
node-version: [18.x, 20.x, 22.x, 24.x]
2121

2222
steps:
2323
- uses: actions/checkout@v4

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
# Node.js Support Policy
2+
3+
- Runtime support: Node.js >= 18
4+
- Development and CI: validated on Node 18.x, 20.x, 22.x, and 24.x
5+
- TypeScript development uses the latest stable Node types (currently v24) without forcing consumers to use a specific Node types version, since `@types/node` is a devDependency.
6+
- The published builds are compiled targeting Node 18 runtime via `tsup` so they remain compatible across supported Node versions.
7+
8+
19
# @airframes/acars-decoder
210

311
This is a no-op documentation tweak to verify repository access, build/lint, tests, and PR workflow. No functional code changes are included.

lib/plugins/Label_H1_OHMA.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ import { DecodeResult, Message, Options } from '../DecoderPluginInterface';
33
import { ResultFormatter } from '../utils/result_formatter';
44

55
import * as zlib from "minizlib";
6+
import { Buffer } from 'node:buffer';
7+
68

79
export class Label_H1_OHMA extends DecoderPlugin {
810
name = 'label-h1-ohma';

lib/utils/miam.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
import * as Base85 from 'base85';
22
import * as zlib from "minizlib";
3+
import { Buffer } from 'node:buffer';
4+
35

46
enum MIAMFid {
57
SingleTransfer = 'T',

package-lock.json

Lines changed: 13 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
"build": "tsup",
1717
"test": "jest"
1818
},
19+
"engines": {
20+
"node": ">=18"
21+
},
1922
"repository": {
2023
"type": "git",
2124
"url": "git+https://github.com/airframesio/acars-decoder-typescript.git"
@@ -27,7 +30,6 @@
2730
"author": "Kevin Elliott <kevin@welikeinc.com>",
2831
"license": "UNLICENSED",
2932
"dependencies": {
30-
"@types/node": "^22.13.10",
3133
"base85": "^3.1.0",
3234
"minizlib": "^3.0.1"
3335
},
@@ -37,6 +39,7 @@
3739
"@babel/preset-typescript": "^7.26.0",
3840
"@types/jest": "^29.5.14",
3941
"@types/minizlib": "^2.1.7",
42+
"@types/node": "^24.2.1",
4043
"babel-jest": "^29.7.0",
4144
"jest": "^29.7.0",
4245
"ts-jest": "^29.2.6",

tsup.config.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@ import { defineConfig } from "tsup";
22

33
export default defineConfig({
44
entry: ["index.ts"],
5-
format: ["cjs", "esm"], // Build for commonJS and ESmodules
6-
dts: true, // Generate declaration file (.d.ts)
5+
format: ["cjs", "esm"],
6+
dts: true,
77
splitting: false,
88
sourcemap: true,
99
clean: true,
10+
target: "node18",
1011
});

0 commit comments

Comments
 (0)