Replace the default workspace with a home screen - #660
Conversation
|
| <StartOption | ||
| color="primary" | ||
| icon="folder_input" | ||
| title="Migrate from another tool" | ||
| description="Postman, Insomnia, OpenAPI, or curl" | ||
| busy={busy === "import"} | ||
| disabled={busy != null} | ||
| onClick={choose("import", () => importData.mutateAsync())} | ||
| /> | ||
| <StartOption | ||
| color="info" | ||
| icon="flask" | ||
| title="Try Yaak with a real API" | ||
| description="Ready-made requests you can send right away" | ||
| busy={busy === "example"} | ||
| disabled={busy != null} | ||
| onClick={choose("example", createExampleWorkspace)} |
There was a problem hiding this comment.
Unsupported web onboarding actions
On a fresh web install, this screen enables actions that the web host cannot run. “Try Yaak with a real API” calls the explicitly declined cmd_create_example_workspace command and shows an error instead of creating a workspace. The import choices also call declined commands, while opening a folder or cloning a repository is unavailable under the web host’s local-file, sync, and Git capabilities. Gate these options by host capability or provide supported web implementations so onboarding does not lead to errors or silent no-ops.
Knowledge Base Used:
There was a problem hiding this comment.
We're going to implement those once the web version is live and promoted
There was a problem hiding this comment.
That makes sense. If the web build isn’t live or promoted yet, I agree this can be deferred as follow-up work rather than blocking this PR. Once it is enabled, the onboarding actions should be gated or implemented before users can reach this screen.
New installs no longer get an empty "Yaak" workspace. With no workspaces, the app shows a home screen to import from Postman, Insomnia, OpenAPI, or curl, open an example workspace, or start fresh. It also links to opening a folder or cloning a Git repository. Deleting the last workspace returns there.
The example workspace uses JSONPlaceholder and covers requests, variables, request chaining, and folder auth. It is created by a new cmd_create_example_workspace command instead of the importer, because the importer remaps request IDs without updating the response() tags that reference them. The web build declines that command for now.
Also removes an unused event sender from WriteDb.