Skip to content

Commit 0ad8326

Browse files
authored
Merge pull request #540 from huseeiin/patch-1
allow URLSearchParams type for when enctype is not set to multipart/form-data
2 parents da72196 + da5e1f9 commit 0ad8326

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/chatty-plants-divide.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@solidjs/router": patch
3+
---
4+
5+
allow URLSearchParams type for when enctype is not set to multipart/form-data

src/data/action.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import type {
1111
import { mockBase } from "../utils.js";
1212
import { cacheKeyOp, hashKey, revalidate, query } from "./query.js";
1313

14-
export type Action<T extends Array<any>, U, V = T> = (T extends [FormData] | []
14+
export type Action<T extends Array<any>, U, V = T> = (T extends [FormData | URLSearchParams] | []
1515
? JSX.SerializableAttributeValue
1616
: unknown) &
1717
((...vars: T) => Promise<NarrowResponse<U>>) & {

0 commit comments

Comments
 (0)