Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 25 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
rust:
- stable

steps:
- uses: actions/checkout@v3
Expand All @@ -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
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -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)
Expand Down
3 changes: 2 additions & 1 deletion justfile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -371,6 +371,7 @@ format:
prettier --write src/*.ts src/**/*.ts examples/*

docs:
#!/bin/bash
typedoc src/mod.ts

serve-docs: docs
Expand Down
2 changes: 1 addition & 1 deletion src/mod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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}.
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"compilerOptions": {
"target": "es2022",
"module": "commonjs",
"module": "esnext",
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"allowImportingTsExtensions": true,
Expand Down