diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml new file mode 100644 index 0000000..ae54a64 --- /dev/null +++ b/.github/workflows/docs.yaml @@ -0,0 +1,47 @@ +name: Generate and deploy docs to pages + +on: + push: + branches: [ "main" ] + +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: "pages" + cancel-in-progress: false + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '22' + - run: npm ci + - run: npm run builddocs + - uses: actions/upload-artifact@v3 + with: + name: docs + path: ./docs + retention-days: 1 + + deploy: + runs-on: ubuntu-latest + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + steps: + - uses: actions/download-artifact@v3 + with: + name: docs + path: ./docs + - uses: actions/configure-pages@v5 + - uses: actions/upload-pages-artifact@v3 + with: + path: './docs' + - uses: actions/deploy-pages@v4 + id: deployment diff --git a/README.md b/README.md index a320c5b..bb6f53b 100644 --- a/README.md +++ b/README.md @@ -107,7 +107,7 @@ export default function Home() { ``` -5. Next run your app and click "Store". After a few seconds you should see `Status: succcess` and `Id: ` rendered. Complete examples are available at [examples/react](./examples/react) or [examples/nextjs](./examples/nextjs). +5. Next run your app and click "Store". After a few seconds you should see `Status: succcess` and `Id: ` rendered. Complete examples are available at [examples/react](https://github.com/NillionNetwork/client-ts/tree/main/examples/react) or [examples/nextjs](https://github.com/NillionNetwork/client-ts/tree/main/examples/nextjs). ## Packages and package hierarchy diff --git a/tsconfig.json b/tsconfig.json index 0b9657a..3967858 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -35,6 +35,7 @@ }, "exclude": [ "docs", + "examples", "node_modules" ] }