You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A minimal, well-commented skeleton application for the Hyperware platform using the Hyperapp framework. This skeleton provides a starting point for building Hyperware applications with a React/TypeScript frontend and Rust backend.
3
+
A minimal, well-commented skeleton application for the Hyperware platform using the Hyperapp framework.
4
+
This skeleton provides a starting point for building Hyperware applications with a React/TypeScript frontend and Rust backend.
4
5
5
-
## Features
6
+
Either prompt your favorite LLM directly with instructions on how to build your app or add them to `instructions.md`!
6
7
7
-
- ✅ Minimal working Hyperware app structure
8
-
- ✅ Well-commented code explaining key concepts
9
-
- ✅ Basic state management with counter example
10
-
- ✅ HTTP endpoints demonstration
11
-
- ✅ React/TypeScript UI with Zustand state management
12
-
- ✅ Error handling and loading states
13
-
- ✅ Automatic WIT generation via hyperprocess macro
@@ -130,17 +158,24 @@ Add system permissions in `manifest.json`:
130
158
]
131
159
```
132
160
161
+
These are required to message other local processes.
162
+
They can also be granted so other local processes can message us.
163
+
There is also a `request_networking` field that must be true to send messages over the network p2p.
164
+
133
165
### 4. Update Frontend
134
166
135
167
1. Add types in `ui/src/types/skeleton.ts`
136
168
2. Add API calls in `ui/src/utils/api.ts`
137
169
3. Update store in `ui/src/store/skeleton.ts`
138
170
4. Modify UI in `ui/src/App.tsx`
139
171
172
+
### 5. Rename as appropriate
173
+
174
+
Change names throughout from `skeleton-app` (and variants) as appropriate if user describes app name.
175
+
140
176
## Common Issues and Solutions
141
177
142
178
### "Failed to deserialize HTTP request"
143
-
- Ensure all HTTP methods have `_request_body` parameter
144
179
- Check parameter format (tuple vs object)
145
180
146
181
### "Node not connected"
@@ -159,31 +194,58 @@ Add system permissions in `manifest.json`:
159
194
160
195
## Testing Your App
161
196
162
-
1.Run a Hyperware node:
197
+
1.Deploy app to a Hyperware node (after building, if requested):
163
198
```bash
164
-
kit s
199
+
kit start-packages
165
200
```
166
-
167
201
2. Your app will be automatically installed and available at `http://localhost:8080`
168
202
3. Check the Hyperware homepage for your app icon
169
203
170
-
## Next Steps
204
+
## Instructions
205
+
206
+
### Create an implementation plan
207
+
208
+
Carefully read the prompt; look carefully at `instructions.md` (if it exists) and in the resources/ directory.
209
+
In particular, note the example applications `resources/example-apps/sign/`, `resources/example-apps/id/`, and `resources/example-apps/file-explorer`.
210
+
`sign` and `id` demonstrate local messaging.
211
+
`file-explorer` demonstrates VFS interactions.
212
+
213
+
Expand the prompt and/or `instructions.md` into a detailed implementation plan.
214
+
The implementor will be starting from this existing template that exists at `skeleton-app/` and `ui/`.
215
+
216
+
Note in particular that bindings for the UI will be generated when the app is built with `kit build --hyperapp`.
217
+
As such, first design and implement the backend; the interface will be generated from the backend; finally design and implement the frontend to consume the interface.
218
+
Subsequent changes to the interface must follow this pattern as well: start in backend, generate interface, finish in frontend
219
+
220
+
Do NOT create the API.
221
+
The API is machine generated.
222
+
You create types that end up in the API by defining and using them in functions in the Rust backend "hyperapp"
223
+
224
+
Do NOT write code: just create a detailed `IMPLEMENTATION_PLAN.md` that will be used by the implementor.
225
+
The implementor will have access to `resources/` but will be working from `IMPLEMENTATION_PLAN.md`, so include all relevant context in the PLAN.
226
+
You can refer the implementor to `resources/` but do not assume the implementor has read them unless you refer them there.
227
+
228
+
### Implement the plan
229
+
230
+
Look carefully at `IMPLEMENTATION_PLAN.md` and in the `resources/` directory, if relevant.
231
+
In particular, note the example applications `resources/example-apps/sign/`, `resources/example-apps/id/`, and `resources/example-apps/file-explorer`.
232
+
Use them if useful.
233
+
234
+
Work from the existing template that exists at `skeleton-app/` and `ui/`.
171
235
172
-
1.**Study the Code**: Read through the well-commented `lib.rs` file
173
-
2.**Experiment**: Try modifying the counter logic or adding new endpoints
174
-
3.**Build Features**: Add your own functionality following the patterns
175
-
4.**Add Capabilities**: Request system permissions as needed for your features
236
+
Note in particular that bindings for the UI will be generated when the app is built with `kit build --hyperapp`.
237
+
As such, first design and implement the backend; the interface will be generated from the backend; finally design and implement the frontend to consume the interface.
238
+
Subsequent changes to the interface must follow this pattern as well: start in backend, generate interface, finish in frontend
176
239
177
-
## Resources
240
+
Do NOT create the API.
241
+
The API is machine generated.
242
+
You create types that end up in the API by defining and using them in functions in the Rust backend "hyperapp"
178
243
179
-
-**Development Guides**: See `resources/guides/` for comprehensive documentation
0 commit comments