diff --git a/.github/workflows/compile.yml b/.github/workflows/compile.yml index 7e03a76..fccad7c 100644 --- a/.github/workflows/compile.yml +++ b/.github/workflows/compile.yml @@ -28,7 +28,7 @@ jobs: node-version: ${{ matrix.node-version }} - run: npm install -g typescript - run: git clone https://github.com/nginx/njs.git && mv njs/ts/ ../type - - run: tsc --target ES2022 --lib ES6 ddns.ts + - run: tsc --target ES2022 --lib ES2022 ddns.ts - name: Upload binaries to release uses: svenstaro/upload-release-action@v2 with: diff --git a/ddns.ts b/ddns.ts index 708789d..13512f5 100644 --- a/ddns.ts +++ b/ddns.ts @@ -1,4 +1,5 @@ -/// +/// +/// /** * AliDDNS njs interface diff --git a/tsconfig.json b/tsconfig.json index bf9a74d..b560dcf 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,6 +2,9 @@ "compilerOptions": { "target": "es5", "module": "ES2022", + "types": [ + "./type" + ], "lib": [ "ES5", // "ES2015.Collection",