Skip to content

Commit ac927df

Browse files
React tutorial (#339)
* formatting updates * react tutorial * add js docs * migrate * add release yaml * add open hands
1 parent 5d75316 commit ac927df

File tree

16 files changed

+6979
-7607
lines changed

16 files changed

+6979
-7607
lines changed

.github/actions/openhands.yaml

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Resolve Issue with OpenHands
2+
3+
on:
4+
issues:
5+
types: [labeled]
6+
pull_request:
7+
types: [labeled]
8+
9+
jobs:
10+
call-openhands-resolver:
11+
uses: All-Hands-AI/openhands-resolver/.github/workflows/openhands-resolver.yml@main
12+
if: github.event.label.name == 'fix-me'
13+
with:
14+
issue_number: ${{ github.event.issue.number || github.event.pull_request.number }}
15+
max_iterations: 50
16+
secrets:
17+
PAT_TOKEN: ${{ secrets.PAT_TOKEN }}
18+
PAT_USERNAME: ${{ secrets.PAT_USERNAME }}
19+
LLM_MODEL: ${{ secrets.LLM_MODEL }}
20+
LLM_API_KEY: ${{ secrets.LLM_API_KEY }}
21+
LLM_BASE_URL: ${{ secrets.LLM_BASE_URL }}

.github/actions/release.yaml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Release
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: "Version to release (e.g., v1.0.0)"
8+
required: true
9+
type: string
10+
dojo_version:
11+
description: "Dojo version to use"
12+
required: true
13+
type: string
14+
15+
jobs:
16+
create-release:
17+
runs-on: ubuntu-latest
18+
env:
19+
DOJO_VERSION: ${{ inputs.dojo_version }}
20+
steps:
21+
- uses: actions/checkout@v3
22+
23+
# Setup and test with specified Dojo version
24+
- run: curl -L https://install.dojoengine.org | bash
25+
- run: /home/runner/.config/.dojo/bin/dojoup -v ${{ env.DOJO_VERSION }}
26+
- run: |
27+
/home/runner/.config/.dojo/bin/sozo build
28+
/home/runner/.config/.dojo/bin/sozo test
29+
30+
# Create tag and release
31+
- name: Create Tag
32+
run: |
33+
git tag ${{ inputs.version }}
34+
git push origin ${{ inputs.version }}
35+
36+
- name: Create Release
37+
uses: softprops/action-gh-release@v1
38+
with:
39+
tag_name: ${{ inputs.version }}
40+
name: Release ${{ inputs.version }}
41+
draft: false
42+
prerelease: false
43+
generate_release_notes: true

docs/pages/client/sdk/javascript.mdx

+17-16
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,29 @@ import { LinkCard } from "../../../components/LinkCard";
44

55
Dojo.js is the official JavaScript package for dojo. It provides a set of tools and utilities to interact with dojo and build JavaScript based apps.
66

7-
::::steps
8-
9-
### init dojo
7+
### Start dojo
108

119
This will provide you with a list of templates to choose from which all have the necessary configuration to get started with dojo.js.
1210

13-
```sh
14-
npx @dojoengine/create-dojo init
11+
```bash
12+
npx @dojoengine/create-dojo start
1513
```
1614

17-
### Install
15+
### Recommended Setup - Using the SDK with React
16+
17+
This will provide you with a starter template for building a React application using the Dojo SDK.
1818

19-
```sh
20-
pnpm i
19+
```bash
20+
npx @dojoengine/create-dojo start -t example-vite-react-sdk
2121
```
2222

23-
::::
23+
Read about the offical SDK [here](/client/sdk/javascript/overview).
24+
2425

25-
<div className="grid grid-cols-2 gap-8">
26-
<LinkCard
27-
title="JavaScript Docs"
28-
description="Learn how to get started with Dojo.js and build your first application."
29-
href="https://github.com/dojoengine/dojo.js"
30-
/>
31-
</div>
26+
### Advanced Setup - Using the SDK with RECS
27+
28+
This will provide you with a starter template for building a React application using the Dojo SDK and RECS state management.
29+
30+
```bash
31+
npx @dojoengine/create-dojo start -t example-vite-react-app-recs
32+
```

0 commit comments

Comments
 (0)