Skip to content

Commit

Permalink
Generate typedoc docs for thirdweb package
Browse files Browse the repository at this point in the history
  • Loading branch information
MananTank committed Jan 29, 2024
1 parent 2d08c42 commit 74ca135
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 21 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/release-artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
push:
branches:
- changeset-release/main
- alpha

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -57,6 +58,7 @@ jobs:
git add packages/sdk/typedoc/documentation.json
git add packages/storage/typedoc/documentation.json
git add packages/wallets/typedoc/documentation.json
git add packages/thirdweb/typedoc/documentation.json
git add snippets/feature_snippets_react.json
git add snippets/feature_snippets_sdk.json
git add snippets/snippets.json
Expand Down
6 changes: 4 additions & 2 deletions packages/thirdweb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,8 @@
"react": "^18.2.0",
"rimraf": "^5.0.5",
"tinybench": "^2.6.0",
"typescript": "^5.3.3"
"typescript": "^5.3.3",
"typedoc-gen": "workspace:*"
},
"peerDependencies": {
"ethers": "^5 || ^6",
Expand All @@ -152,7 +153,8 @@
"build:types": "tsc --project ./tsconfig.build.json --module esnext --declarationDir ./types --emitDeclarationOnly --declaration --declarationMap",
"clean": "rimraf esm cjs types",
"push": "yalc push",
"test": "bun test"
"test": "bun test",
"typedoc": "node scripts/typedoc.mjs"
},
"engines": {
"node": ">=18"
Expand Down
21 changes: 21 additions & 0 deletions packages/thirdweb/scripts/typedoc.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/* eslint-disable better-tree-shaking/no-top-level-side-effects */

// @ts-check
import { typedoc } from "typedoc-gen";

typedoc({
entryPoints: [
"src/index.ts",
"src/react/index.tsx",
"src/adapters/ethers5.ts",
"src/adapters/ethers6.ts",
"src/event/index.ts",
"src/extensions/erc20.ts",
"src/extensions/erc721.ts",
"src/rpc/index.ts",
"src/storage/index.ts",
"src/transaction/index.ts",
"src/wallets/index.ts",
],
exclude: [],
});
2 changes: 1 addition & 1 deletion packages/typedoc-gen/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "",
"license": "ISC",
"dependencies": {
"typedoc": "^0.25.2"
"typedoc": "^0.25.7"
},
"devDependencies": {
"prettier": "^3.1.1",
Expand Down
33 changes: 15 additions & 18 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 74ca135

Please sign in to comment.