chore: rework useSubmit (#2649)

rework useSubmit
This commit is contained in:
Bernd Storath
2026-06-03 10:08:07 +02:00
committed by GitHub
parent e03d743307
commit bc95a2851f
16 changed files with 124 additions and 127 deletions
+5 -4
View File
@@ -40,10 +40,11 @@ const { data: _data, refresh } = await useFetch(`/api/admin/hooks`, {
const data = toRef(_data.value);
const _submit = useSubmit(
`/api/admin/hooks`,
{
method: 'post',
},
(data) =>
$fetch(`/api/admin/hooks`, {
method: 'post',
body: data,
}),
{ revert }
);