From 52b28cb0d3d62ec4c8d4b0ba97f2635457d71120 Mon Sep 17 00:00:00 2001 From: Leo Ribeiro Date: Mon, 23 Oct 2023 16:25:50 -0400 Subject: [PATCH] Install tbdocs for @web5/api --- .github/workflows/tests-ci.yml | 33 +++++++++++++++++++++++++++++++++ packages/api/src/index.ts | 29 +++++++++++++++++++++++++++-- 2 files changed, 60 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests-ci.yml b/.github/workflows/tests-ci.yml index cf98b6b5f..04c379a58 100644 --- a/.github/workflows/tests-ci.yml +++ b/.github/workflows/tests-ci.yml @@ -107,3 +107,36 @@ jobs: run: npm run test:browser --ws -- --color env: TEST_DWN_URL: http://localhost:3000 + + tbdocs-reporter: + runs-on: ubuntu-latest + steps: + - name: Checkout source + uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 + + - name: Set up Node.js + uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 + with: + node-version: 18 + registry-url: https://registry.npmjs.org/ + + - name: Install latest npm + run: npm install -g npm@latest + + - name: Install dependencies + run: npm ci + + - name: Build all workspace packages + run: npm run build + + - name: TBDocs Reporter + id: tbdocs-reporter-protocol + uses: TBD54566975/tbdocs@main + with: + token: ${{ secrets.GITHUB_TOKEN }} + report_changed_scope_only: false + fail_on_error: false + entry_points: | + - file: packages/api/src/index.ts + docsReporter: api-extractor + docsGenerator: typedoc-markdown diff --git a/packages/api/src/index.ts b/packages/api/src/index.ts index 7d4221c35..9c420aba6 100644 --- a/packages/api/src/index.ts +++ b/packages/api/src/index.ts @@ -1,8 +1,33 @@ +/** + * Making developing with Web5 components at least 5 times easier to work with. + * + * Web5 consists of the following components: + * - Decentralized Identifiers + * - Verifiable Credentials + * - DWeb Node personal datastores + * + * The SDK sets out to gather the most oft used functionality from all three of + * these pillar technologies to provide a simple library that is as close to + * effortless as possible. + * + * The SDK is currently still under active development, but having entered the + * Tech Preview phase there is now a drive to avoid unnecessary changes unless + * backwards compatibility is provided. Additional functionality will be added + * in the lead up to 1.0 final, and modifications will be made to address + * issues and community feedback. + * + * [Link to GitHub Repo](https://github.com/TBD54566975/web5-js) + * + * @packageDocumentation + */ + export * from './did-api.js'; export * from './dwn-api.js'; export * from './protocol.js'; export * from './record.js'; -export * as utils from './utils.js'; export * from './vc-api.js'; export * from './web5.js'; -export * from './tech-preview.js'; \ No newline at end of file +export * from './tech-preview.js'; + +import * as utils from './utils.js'; +export { utils }; \ No newline at end of file