J/template hyperapp#380
Conversation
| [workspace] | ||
| members = [ | ||
| "skeleton-app", | ||
| "target/hyperapp-skeleton-caller-utils", |
There was a problem hiding this comment.
remove this; we want the wildcard below but not this one
the reason is for building from scratch: when building from scratch the wildcard version is happy but the non-wildcard version complains
There was a problem hiding this comment.
Fresh builds work with or without that line for me. Remove the line or keep? Your choice.
There was a problem hiding this comment.
Remove, just keep the wildcard
|
|
||
| [features] | ||
| caller-utils = ["hyperapp_skeleton_caller_utils"] | ||
| default = ["caller-utils"] |
There was a problem hiding this comment.
I think we should remove this because it will interfere with fresh builds. We should test to confirm/falsify: does this mess up building fresh?
There was a problem hiding this comment.
Again, doesn’t make a diff with fresh builds. Remove or keep, your choice.
| use hyperprocess_macro::hyperprocess; | ||
|
|
||
| // HYPERWARE PROCESS LIB IMPORTS | ||
| // These are provided by the hyperprocess_macro, DO NOT add hyperware_process_lib to Cargo.toml |
any reason not to make |
|
In the last commit, removed api.ts, and wired up caller-utils.ts correctly. |
|
Re previous change request to remove vite-env.d.ts. Keeping that because it's useful in Vite projects. |
|
New file explorer wired up. Last detail - keeping the api folder in that one (since its an example, and we dont expect people to build it), or removing it? |
nick1udwig
left a comment
There was a problem hiding this comment.
Almost there, a few more comments
| // UI state | ||
| isLoading: boolean; | ||
| error: string | null; | ||
| } No newline at end of file |
There was a problem hiding this comment.
I think this file should be removed
There was a problem hiding this comment.
I removed the api related types (as thats LLM bad habit), but kept the interface SkeletonStore type as types/skeleton.ts is a clean place for LLMs to update types to match the rust backend
| @@ -0,0 +1,2 @@ | |||
| // Re-export everything from caller-utils | |||
| export * from '../../../target/ui/caller-utils'; No newline at end of file | |||
There was a problem hiding this comment.
Future TODO: remove these ui/src/types/api.ts files and update imports to point to the caller-utils file themselves. This api.ts is a bad pattern that LLMs are already prone to, so we shouldn't demo it for them even more
| @@ -0,0 +1,2 @@ | |||
| // Re-export everything from the generated caller-utils | |||
| export * from '../types/api'; No newline at end of file | |||
There was a problem hiding this comment.
ditto on "future TODO": eventually remove this
|
|
||
| ### 5. Rename as appropriate | ||
|
|
||
| Change names throughout from `skeleton-app` (and variants) as appropriate if user describes app name. |
There was a problem hiding this comment.
the name should match the template name (i.e. both should be hyperapp-skeleton) throughout so that kit will appropriately rename stuff throughout (i.e. when you do kit new foo --template hyperapp-skeleton --ui it will rename the package and process to foo -- but only if the names throughout properly match the template name)
There was a problem hiding this comment.
Ok, so I renamed it here to hyperapp-skeleton, but imo this deserves its own PR to make sure kit renames things properly (and should be done by kit rather than llms to be deterministic). Just at first glance, e.g. metadata.json doesn't get changed at all, and there are likely other places which require renaming. So, punt for other PR?
There was a problem hiding this comment.
Ok, we can push back to another PR, but if so we are agreeing we will not make a new kit release until we have it in
I'm fine keeping it, but we should add a note in README or something to that effect |
This reverts commit 65597a2.
nick1udwig
left a comment
There was a problem hiding this comment.
lgtm, nice work! let's merge and make some follow-up issues so we don't lose track of the TODOs here in the comments
Insert hyperapp skeleton into kit templates.
I made a few changes to hyperapp skeleton which are not easily visible here (due to the whole repo being new, rather than just diffs), so here are the relevant ones to inspect:
kit/src/new/templates/rust/ui/hyperapp-skeleton/Cargo.toml
Lines 7 to 11 in 8556e3b
kit/src/new/templates/rust/ui/hyperapp-skeleton/skeleton-app/Cargo.toml
Lines 7 to 9 in 8556e3b
kit/src/new/templates/rust/ui/hyperapp-skeleton/skeleton-app/Cargo.toml
Lines 24 to 26 in 8556e3b
kit/src/new/templates/ui/hyperapp-skeleton/ui/src/utils/api.ts
Lines 8 to 18 in 8556e3b
kit/src/new/templates/ui/hyperapp-skeleton/ui/src/utils/api.ts
Lines 34 to 43 in 8556e3b
There is a few more but these are the significant ones. It's basically the changes required to make hyperapp-skeleton run out of the box with
kit bs --hyperappas soon it's generated from the template.kit new --template hyperapp-skeleton skel-template-new-dir --uiworks now.