nuxt-outfit 1.0.3 → 1.0.5
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.
- package/dist/module.json +1 -1
- package/dist/runtime/composables/useDetectOutsideClick.mjs +1 -0
- package/dist/runtime/composables/useEcho.mjs +1 -0
- package/dist/runtime/composables/useForm.d.ts +2 -2
- package/dist/runtime/composables/useForm.mjs +2 -0
- package/dist/runtime/composables/useSpaHeaders.mjs +2 -1
- package/package.json +1 -1
package/dist/module.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export declare const useForm: (opts?: {}) => {
|
|
2
2
|
fields: any;
|
|
3
|
-
errors:
|
|
3
|
+
errors: import("vue").Ref<{}>;
|
|
4
4
|
repeatArray: (property: any) => void;
|
|
5
5
|
removeArray: (property: any, index: any) => void;
|
|
6
|
-
isPending:
|
|
6
|
+
isPending: import("vue").Ref<boolean>;
|
|
7
7
|
handleSubmit: () => Promise<void>;
|
|
8
8
|
clearError: (field: any) => void;
|
|
9
9
|
reset: () => void;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useRuntimeConfig, useRequestEvent, useRequestHeaders } from "#imports";
|
|
1
2
|
import { appendHeader } from "h3";
|
|
2
3
|
import { parse, splitCookiesString as split } from "set-cookie-parser";
|
|
3
4
|
import { serialize } from "cookie";
|
|
@@ -12,7 +13,7 @@ export const useSpaHeaders = (additionalHeaders = {}) => {
|
|
|
12
13
|
const headers = useRequestHeaders(["cookie", "referer", "host"]);
|
|
13
14
|
const goodResponses = [200, 201, 202, 203, 204, 205, 206, 207, 208, 226];
|
|
14
15
|
if (!Object.prototype.hasOwnProperty.call(headers, "referer")) {
|
|
15
|
-
headers.referer = `${headers.host}/${event.req.originalUrl}`;
|
|
16
|
+
headers.referer = `${headers.host}/${event.node.req.originalUrl}`;
|
|
16
17
|
}
|
|
17
18
|
const parseCookie = (cookies) => {
|
|
18
19
|
return parse(split(cookies)).map((cookie) => serialize(cookie.name, cookie.value, cookie));
|