diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4c17809..7843d19 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,8 +13,6 @@ jobs: strategy: matrix: os: [ubuntu-latest, macos-latest, windows-latest] - rust: - - stable steps: - uses: actions/checkout@v3 @@ -35,3 +33,28 @@ jobs: - name: Test run: npm run test + + docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - uses: extractions/setup-just@v1 + + - uses: actions/setup-node@v3.8.1 + with: + node-version: lts/* + check-latest: true + + - uses: denoland/setup-deno@v1.1.2 + + - uses: oven-sh/setup-bun@v1 + if: ${{ matrix.os != 'windows-latest' }} + with: + bun-version: latest + + - name: Docs + shell: bash + run: | + just prepare + just docs diff --git a/README.md b/README.md index 74b62bc..cba1c50 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,5 @@ # Extism JS SDK -> *Note*: This houses the 1.0 pre-release version of the JavaScript SDK. We may push breaking changes in new versions until will hit 1.0 in December, 2023. But it's currently the best place to start a new integration and we welcome any feedback. - This is a universal JavaScript SDK for Extism. It works in all the major JavaScript runtimes: * Browsers (Firefox, Chrome, WebKit) diff --git a/justfile b/justfile index 1ebc6c8..6fa62bf 100644 --- a/justfile +++ b/justfile @@ -119,7 +119,7 @@ _build out args='[]': prepare fi # build types (TODO: switch module target based on incoming args) - tsc --emitDeclarationOnly --module esnext --project ./tsconfig.json --declaration --outDir dist/{{ out }} + tsc --emitDeclarationOnly --project ./tsconfig.json --declaration --outDir dist/{{ out }} build_worker out args='[]': #!/bin/bash @@ -371,6 +371,7 @@ format: prettier --write src/*.ts src/**/*.ts examples/* docs: + #!/bin/bash typedoc src/mod.ts serve-docs: docs diff --git a/src/mod.ts b/src/mod.ts index ace467b..fb5dc86 100644 --- a/src/mod.ts +++ b/src/mod.ts @@ -47,7 +47,7 @@ export type { CallContext, CallContext as CurrentPlugin } from './call-context.t * } * ``` * - * {@link Plugin | `Plugin`} default to running on a background thread when the + * {@link Plugin | `Plugin`} can run on a background thread when the * environment supports it. You can see if the current environment supports * background plugins by checking the {@link Capabilities#hasWorkerCapability | * `hasWorkerCapability`} property of {@link CAPABILITIES}. diff --git a/tsconfig.json b/tsconfig.json index 0dfa102..0ac1e5f 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,7 +1,7 @@ { "compilerOptions": { "target": "es2022", - "module": "commonjs", + "module": "esnext", "esModuleInterop": true, "forceConsistentCasingInFileNames": true, "allowImportingTsExtensions": true,