solid-start icon indicating copy to clipboard operation
solid-start copied to clipboard

[Feature]:add with-server-actions example and bug resistant package to execute them safely

Open haseeb5555 opened this issue 1 year ago • 2 comments

This pull request adds a new example to the project titled "with-server-actions". The purpose of this addition is to showcase how to safely execute server actions by integrating the solid-safe-action package with Zod for data validation.

Key Changes:

~Added a new example demonstrating the integration of server actions using the solid-safe-action package with Zod for type-safe data validation. ~Integrated Zod schema for validating input data both on the frontend and backend, ensuring that the data type expected by the server action is enforced. ~Demonstrated the usage of the useSafeAction hook provided by solid-safe-action to safely execute server actions, handling success and error states reliably. ~Included comments to explain the purpose and usage of the added example, highlighting its benefits for ensuring type safety and data validation.

haseeb5555 avatar Feb 08 '24 21:02 haseeb5555

⚠️ No Changeset found

Latest commit: 1e1478ffb6ce296fdf63c67f7ef931fac871fe3a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

changeset-bot[bot] avatar Feb 08 '24 21:02 changeset-bot[bot]