react-server-actions 1.0.6 → 1.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +3 -2
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -137,8 +137,9 @@ const userSchema = z.object({
137
137
  import { userSchema } from './schema';
138
138
  import { action } from 'react-server-actions';
139
139
  export const createUser = action(userSchema, async (data) => {
140
- // Your server logic here
141
- return { success: true, data };
140
+ // Your server logic here...
141
+ // Then return whatever you want, also void. The action wrapper will wrap your response into an ActionResult object
142
+ return { message: 'Cool!' };
142
143
  });
143
144
  ```
144
145
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-server-actions",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "A package for working with actions in React and Next.js",
5
5
  "keywords": [
6
6
  "next",