Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start docs #87

Merged
merged 8 commits into from
Dec 20, 2023
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
Binary file added .DS_Store
Binary file not shown.
3 changes: 3 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,13 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: oven-sh/setup-bun@v1

- name: Install dependencies
run: bun link

- name: Install dependencies
run: bun install

- name: Run Prettier
run: bun x prettier --check .

Expand Down
49 changes: 49 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: "typedoc"

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read
pages: write
id-token: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: oven-sh/setup-bun@v1

- name: Install Protobuf Compiler
run: sudo apt-get install -y protobuf-compiler

- name: Install dependencies
run: bun link

- name: Install dependencies
run: bun install

- name: Build dependencies
run: bun run build

- name: Build docs
run: bun run docs

- uses: actions/upload-pages-artifact@v2
with:
path: ./docs
deploy:
runs-on: ubuntu-latest
environment:
name: githubs
url: ${{ steps.deployment.outputs.page_url }}
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
# https://github.com/actions/deploy-pages
uses: actions/deploy-pages@v2
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
node_modules
docs
Binary file modified bun.lockb
Binary file not shown.
File renamed without changes
8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@
"devDependencies": {
"lerna": "^8.0.0",
"prettier": "^3.0.3",
"tsup": "^8.0.1"
"tsup": "^8.0.1",
"typedoc": "^0.25.4",
"typedoc-material-theme": "^1.0.1",
"typedoc-plugin-coverage": "^2.2.0"
},
"scripts": {
"build-core": "bun run --cwd packages/core build",
Expand All @@ -31,7 +34,8 @@
"clean": "rm -rf node_modules packages/create-burner/node_modules node_modules packages/create-dojo/node_modules packages/core/node_modules packages/utils/node_modules packages/torii-client/node_modules packages/torii-wasm/node_modules packages/react/node_modules bun.lockb packages/create-burner/bun.lockb packages/core/bun.lockb packages/utils/bun.lockb packages/torii-client/bun.lockb packages/torii-wasm/bun.lockb packages/react/bun.lockb && rm -rf examples/react-app/node_modules examples/react-app/bun.lockb examples/react-phaser-example/node_modules examples/react-phaser-example/bun.lockb",
"prettier-check": "bun x prettier --check .",
"prettier": "bun x prettier --write .",
"release": "bun run build && bun run prettier && npx lerna publish --no-private --force-publish"
"release": "bun run build && bun run prettier && npx lerna publish --no-private --force-publish",
"docs": "npx typedoc --out docs"
},
"dependencies": {}
}
2 changes: 1 addition & 1 deletion packages/create-burner/src/manager/burnerManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ export class BurnerManager {
const burners: BurnerStorage = JSON.parse(text);

// Assume no burner is active
let activeAddress = null;
let activeAddress: string | null = null;

// Iterate over the pasted burners to find the active one
for (const [address, burner] of Object.entries(burners)) {
Expand Down
3 changes: 2 additions & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"license": "MIT",
"peerDependencies": {
"react": "^18.2.0",
"starknet": "^5.19.0"
"starknet": "^5.24.3",
"type-fest": "^2.14.0"
},
"exports": {
".": {
Expand Down
69 changes: 69 additions & 0 deletions pnpm-lock.yaml

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

4 changes: 1 addition & 3 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- markdownlint-disable -->
<div align="center">
<img src=".github/dojo-mark-full-dark.svg" height="128">
<img src="./media/dojo-mark-full-dark.svg" height="128">
</div>
<div align="center">
<br />
Expand All @@ -26,8 +26,6 @@

**Dojo is a community driven open-source, Provable Game Engine, providing a comprehensive toolkit for building verifiable games and autonomous worlds.**

Here's a more refined and structured version:

---

## Dojo Engine Packages Monorepo
Expand Down
36 changes: 36 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"compilerOptions": {
"target": "ESNext" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
"jsx": "react-jsx" /* Specify what JSX code is generated. */,
"experimentalDecorators": true /* Enable experimental support for TC39 stage 2 draft decorators. */,

/* Modules */
"module": "ESNext" /* Specify what module code is generated. */,
"moduleResolution": "node" /* Specify how TypeScript looks up a file from a given module specifier. */,
"baseUrl": "./src" /* Specify the base directory to resolve non-relative module names. */,

/* Emit */
"noEmit": true /* Disable emitting files from a compilation. */,

/* Interop Constraints */
"esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */,
"forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */,

/* Type Checking */
"strict": true /* Enable all strict type-checking options. */,
"noFallthroughCasesInSwitch": true /* Enable error reporting for fallthrough cases in switch statements. */,

/* Completeness */
"skipLibCheck": true /* Skip type checking all .d.ts files. */,
"resolveJsonModule": true,
"allowImportingTsExtensions": true,
"noImplicitAny": false
},
"include": ["./packages"],
"exclude": [
"node_modules",
"./node_modules",
"./node_modules/*",
"./node_modules/@types/node/index.d.ts"
]
}
27 changes: 27 additions & 0 deletions typedoc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"plugin": ["typedoc-material-theme", "typedoc-plugin-coverage"],
"themeColor": "#cb9820",
"$schema": "https://typedoc.org/schema.json",
"name": "dojo.js docs",
"entryPoints": [
"./packages/core/src/index.ts",
"./packages/react/src/index.ts",
"./packages/create-burner/src/index.ts",
"./packages/utils/src/index.ts",
"./packages/torii-client/src/index.ts"
],
"sort": ["source-order"],
"media": "media",
"categorizeByGroup": false,
"searchCategoryBoosts": {
"Component": 2,
"Model": 1.2
},
"searchGroupBoosts": {
"Classes": 1.5
},
"navigationLinks": {
"Docs": "https://dojoengine.github.io/dojo.js",
"GitHub": "https://github.com/dojoengine/dojo.js"
}
}