Skip to content

docs(js): add TypeDoc-generated docs #36

docs(js): add TypeDoc-generated docs

docs(js): add TypeDoc-generated docs #36

Workflow file for this run

name: Build docs
on:
push:
branches: [master]
pull_request:
branches: [master]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: deploy
cancel-in-progress: false
jobs:
build-rust:
name: Build rustdoc
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Configure cache
uses: Swatinem/rust-cache@v2
- name: Clean docs folder
run: cargo clean --doc
- name: Build docs
run: RUSTFLAGS='--cfg reqwest_unstable' cargo doc --no-deps --manifest-path impit/Cargo.toml
- name: Remove lock file
run: rm target/doc/.lock
- name: Copy redirect
run: cp impit/docs/index.html target/doc/index.html
- name: Upload artifact
uses: actions/upload-artifact@v5
with:
path: target/doc/
build-node:
name: Build typedoc
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Configure cache
uses: Swatinem/rust-cache@v2
- name: Setup Node.js
uses: actions/setup-node@v5
with:
node-version: '24'
- name: Install dependencies
run: cd impit-node && yarn
- name: Build docs
run: cd impit-node && yarn docs
- name: Upload artifact
uses: actions/upload-artifact@v5
with:
path: impit-node/docs/
# deploy:
# name: Deploy
# if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request'
# environment:
# name: github-pages
# url: ${{ steps.deployment.outputs.page_url }}
# runs-on: ubuntu-latest
# needs: build-rust
# steps:
# - name: Deploy to GitHub Pages
# id: deployment
# uses: actions/deploy-pages@v4