Skip to content

Conversation

@AdityaHegde
Copy link
Collaborator

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

Copy link
Contributor

@ericpgreen2 ericpgreen2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving - this is a clean migration that follows the established sveltekit-superforms patterns used elsewhere in the codebase.

A few minor suggestions to consider:

  1. Unused type export: BookmarkFormValues in web-admin/src/features/bookmarks/utils.ts is now unused since its import was removed. Consider deleting it to avoid dead code.

  2. Redundant button attributes: The Save button has both onClick={submit} and submitForm/form={formId}. Having both may cause double-submission in edge cases. I'd suggest either:

    • <Button onClick={submit} type="primary">Save</Button> (matching the pattern in OrgNameSettings.svelte)
    • Or <Button type="primary" form={formId} submitForm>Save</Button> (relying on native form submission)
  3. Error handling: The onUpdate handler doesn't wrap the mutation calls in try/catch. If the mutations throw, users won't see feedback. Other forms like OrgNameSettings.svelte handle this by catching errors and setting form.errors. Worth considering for consistency.

None of these are blockers.


Developed in collaboration with Claude Code

@AdityaHegde
Copy link
Collaborator Author

Thanks @ericpgreen2 . Handled 1 and 2. For 3 I used the mutation errors directly. In OrgNameSettings.svelte we are adding the error directly to a field so we need that separate handling. We can circle back on the standard we want to follow in the project and updated in all places.

@AdityaHegde AdityaHegde merged commit fb46e8b into main Jan 5, 2026
10 checks passed
@AdityaHegde AdityaHegde deleted the chore/remove-svelte-forms-lib branch January 5, 2026 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants