Skip to content

Commit c39197f

Browse files
committed
Use URLSearchParams
1 parent 18a8e2c commit c39197f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

__tests__/html2/basic/longURL.keepAll.html

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22
<html>
33
<head>
44
<script>
5-
location = './longURL?break=keep-all&text=箸より重いものを持ったことがない箸より重いものを持ったことがない';
5+
const url = new URL('./longURL', location);
6+
7+
url.searchParams.set('break', 'keep-all');
8+
url.searchParams.set('text', '箸より重いものを持ったことがない箸より重いものを持ったことがない');
9+
10+
location = url;
611
</script>
712
</head>
813
<body></body>

0 commit comments

Comments
 (0)