routesync 1.0.12 → 1.0.13

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/dist/cli.js +3 -0
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -8866,6 +8866,9 @@ var NextActionGenerator = class {
8866
8866
  const actionName = `${groupName}${toTypeName(route.actionName)}`;
8867
8867
  lines.push(`export async function ${actionName}Action(payload?: Record<string, unknown>) {`);
8868
8868
  const args = [];
8869
+ if (route.path.includes(":")) {
8870
+ args.push(`params: payload as any`);
8871
+ }
8869
8872
  if (route.method === "GET") {
8870
8873
  args.push(`query: payload`);
8871
8874
  } else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "routesync",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "description": "Laravel routes to typed frontend SDKs.",
5
5
  "main": "./dist/sdk.js",
6
6
  "module": "./dist/sdk.mjs",