flowrix 1.0.1-beta.87 → 1.0.1-beta.88
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/module.mjs +6 -4
- package/dist/runtime/composables/Checkout/useCheckout.js +47 -8
- package/dist/runtime/server/api/banners.js +2 -4
- package/dist/runtime/server/api/brand/[...slug].js +2 -4
- package/dist/runtime/server/api/catalog/categories.js +2 -4
- package/dist/runtime/server/api/catalog/categoriesall.js +2 -4
- package/dist/runtime/server/api/catalog/featured.js +2 -4
- package/dist/runtime/server/api/catalog/samples.js +2 -4
- package/dist/runtime/server/api/catalog/search.js +2 -4
- package/dist/runtime/server/api/category/[...slug].js +1 -0
- package/dist/runtime/server/api/cmspost/[...slug].js +2 -4
- package/dist/runtime/server/api/countries.js +2 -4
- package/dist/runtime/server/api/generate/sitemap.get.d.ts +4 -1
- package/dist/runtime/server/api/generate/sitemap.get.js +5 -24
- package/dist/runtime/server/api/page/[...slug].js +2 -4
- package/dist/runtime/server/api/product/[...slug].js +2 -4
- package/dist/runtime/server/api/service/[slug].js +2 -4
- package/dist/runtime/server/api/service/getall.js +2 -4
- package/package.json +22 -8
- package/dist/runtime/server/api/generate/robots.get.d.ts +0 -2
- package/dist/runtime/server/api/generate/robots.get.js +0 -20
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -14,8 +14,7 @@ const module$1 = defineNuxtModule({
|
|
|
14
14
|
runtimeConfig.FLOWRIX_API_ORIGIN ||= env.FLOWRIX_API_ORIGIN || "";
|
|
15
15
|
runtimeConfig.FLOWRIX_API_BASE ||= env.FLOWRIX_API_BASE || "";
|
|
16
16
|
runtimeConfig.FLOWRIX_API_BASE_V2 ||= env.FLOWRIX_API_BASE_V2 || "";
|
|
17
|
-
runtimeConfig.FLOWRIX_CACHE ||= env.FLOWRIX_CACHE ||
|
|
18
|
-
runtimeConfig.FLOWRIX_CDN ||= env.FLOWRIX_CDN || "";
|
|
17
|
+
runtimeConfig.FLOWRIX_CACHE ||= env.FLOWRIX_CACHE || "";
|
|
19
18
|
Object.assign(runtimeConfig.public, {
|
|
20
19
|
...runtimeConfig.public,
|
|
21
20
|
FLOWRIX_API_KEY: runtimeConfig.public.FLOWRIX_API_KEY || env.FLOWRIX_API_KEY || "",
|
|
@@ -23,8 +22,7 @@ const module$1 = defineNuxtModule({
|
|
|
23
22
|
FLOWRIX_API_ORIGIN: runtimeConfig.public.FLOWRIX_API_ORIGIN || env.FLOWRIX_API_ORIGIN || "",
|
|
24
23
|
FLOWRIX_API_BASE: runtimeConfig.public.FLOWRIX_API_BASE || env.FLOWRIX_API_BASE || "",
|
|
25
24
|
FLOWRIX_API_BASE_V2: runtimeConfig.public.FLOWRIX_API_BASE_V2 || env.FLOWRIX_API_BASE_V2 || "",
|
|
26
|
-
FLOWRIX_CACHE: runtimeConfig.public.FLOWRIX_CACHE || env.FLOWRIX_CACHE ||
|
|
27
|
-
FLOWRIX_CDN: runtimeConfig.public.FLOWRIX_CDN || env.FLOWRIX_CDN || ""
|
|
25
|
+
FLOWRIX_CACHE: runtimeConfig.public.FLOWRIX_CACHE || env.FLOWRIX_CACHE || ""
|
|
28
26
|
});
|
|
29
27
|
const resolver = createResolver(import.meta.url);
|
|
30
28
|
await installModule("@pinia/nuxt");
|
|
@@ -330,6 +328,10 @@ const module$1 = defineNuxtModule({
|
|
|
330
328
|
route: "/api/cache/**",
|
|
331
329
|
handler: resolver.resolve("./runtime/server/api/cache/[...slug].delete")
|
|
332
330
|
});
|
|
331
|
+
addServerHandler({
|
|
332
|
+
route: "/sitemap/**",
|
|
333
|
+
handler: resolver.resolve("./runtime/server/api/generate/sitemap.get")
|
|
334
|
+
});
|
|
333
335
|
}
|
|
334
336
|
});
|
|
335
337
|
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { ref, computed, watch, onMounted, defineAsyncComponent } from "vue";
|
|
2
2
|
import { useCompanyProfile } from "../../stores/useCompanyProfile.js";
|
|
3
3
|
import { useCartStore } from "../../stores/Cart.js";
|
|
4
|
+
import { GTM_begin_checkout, GTM_add_shipping_info, GTM_add_payment_info } from "../../composables/useDataLayer.js";
|
|
5
|
+
import { META_begin_checkout, META_add_shipping_info, META_add_payment_info } from "../../composables/useMetaLayer.js";
|
|
6
|
+
import { TikTok_begin_checkout, TikTok_add_payment_info } from "../../composables/useTikTokDatalayer.js";
|
|
4
7
|
import { useCheckoutStore } from "../../stores/Checkout.js";
|
|
5
8
|
import { useCountry } from "../Extras/useCountry.js";
|
|
6
9
|
import { useRouter, useRoute } from "vue-router";
|
|
@@ -147,10 +150,51 @@ export default function() {
|
|
|
147
150
|
onMounted(() => {
|
|
148
151
|
checkoutStore.getConfig();
|
|
149
152
|
updateUserFieldsIfuserLogin(inputData.value.shippingasbilling);
|
|
150
|
-
const
|
|
151
|
-
|
|
153
|
+
const cartInfo = [];
|
|
154
|
+
cartInfo.items = checkoutStore.config.cartInfo;
|
|
155
|
+
cartInfo.totals = checkoutStore?.config?.calculations ? checkoutStore?.config?.calculations : "";
|
|
156
|
+
let shippingmethods = checkoutStore.config.shippingmethods;
|
|
157
|
+
let shipping_method = shippingmethods.filter((method) => method.selected == true)[0];
|
|
152
158
|
let deliverymethods = checkoutStore.config.preferences;
|
|
153
159
|
let deliverymethod = false;
|
|
160
|
+
let delivery_method = deliverymethods.filter((method) => method.selected == true)[0];
|
|
161
|
+
if (delivery_method) {
|
|
162
|
+
if (delivery_method.id == 1) {
|
|
163
|
+
if (shipping_method) {
|
|
164
|
+
GTM_add_shipping_info(cartStore?.cart, shipping_method);
|
|
165
|
+
META_add_shipping_info(cartStore?.cart, shipping_method);
|
|
166
|
+
}
|
|
167
|
+
} else if (delivery_method.id == 2) {
|
|
168
|
+
shipping_method = {
|
|
169
|
+
"id": 0,
|
|
170
|
+
"title": "Click and Collect",
|
|
171
|
+
"details": "",
|
|
172
|
+
"available": 1,
|
|
173
|
+
"price": 0,
|
|
174
|
+
"selected": true
|
|
175
|
+
};
|
|
176
|
+
GTM_add_shipping_info(cartStore?.cart, shipping_method);
|
|
177
|
+
META_add_shipping_info(cartStore?.cart, shipping_method);
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
if (cartStore?.cart) {
|
|
181
|
+
GTM_begin_checkout(cartStore?.cart);
|
|
182
|
+
META_begin_checkout(cartStore?.cart);
|
|
183
|
+
TikTok_begin_checkout(cartStore?.cart);
|
|
184
|
+
GTM_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
185
|
+
META_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
186
|
+
TikTok_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
187
|
+
}
|
|
188
|
+
});
|
|
189
|
+
watch(() => cartStore?.cart, (newCartData) => {
|
|
190
|
+
if (newCartData) {
|
|
191
|
+
GTM_begin_checkout(newCartData);
|
|
192
|
+
META_begin_checkout(newCartData);
|
|
193
|
+
TikTok_begin_checkout(newCartData);
|
|
194
|
+
GTM_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
195
|
+
META_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
196
|
+
TikTok_add_payment_info(cartStore?.cart, inputData.value.paymentmethod);
|
|
197
|
+
}
|
|
154
198
|
});
|
|
155
199
|
const totalPrice = computed(() => {
|
|
156
200
|
return checkoutStore.config ? checkoutStore.config?.calculations?.total : 0;
|
|
@@ -168,7 +212,7 @@ export default function() {
|
|
|
168
212
|
}
|
|
169
213
|
return states.value;
|
|
170
214
|
});
|
|
171
|
-
watch(inputData.value, async (newData, oldValue) => {
|
|
215
|
+
watch(() => inputData.value, async (newData, oldValue) => {
|
|
172
216
|
});
|
|
173
217
|
const shippingMethods = computed(() => {
|
|
174
218
|
if (checkoutStore.config) {
|
|
@@ -226,7 +270,6 @@ export default function() {
|
|
|
226
270
|
};
|
|
227
271
|
payment.tokenize(
|
|
228
272
|
data,
|
|
229
|
-
//additional data, MUST include card_holder (or first_name & last_name), month and year
|
|
230
273
|
function(token2, cardData) {
|
|
231
274
|
inputData2.clientsceret = token2;
|
|
232
275
|
checkoutStore.publishableKey.clientsceret = token2;
|
|
@@ -279,19 +322,15 @@ export default function() {
|
|
|
279
322
|
inputData.value.clientsceret
|
|
280
323
|
);
|
|
281
324
|
if (sessiondata.value.calculations.total > 0) {
|
|
282
|
-
console.log("chckoutResponse", sessiondata.value);
|
|
283
|
-
console.log("chckoutResponse", checkoutStore.responseData.booking ? `${window.location.origin}${url_booking}?calendar=${checkoutStore.responseData.calendar}&order_no=${checkoutStore.responseData.order_no}` : `${window.location.origin}${url_success}`);
|
|
284
325
|
const { error: error2 } = await stripe.confirmPayment({
|
|
285
326
|
elements,
|
|
286
327
|
confirmParams: {
|
|
287
|
-
// Make sure to change this to your payment completion page
|
|
288
328
|
return_url: checkoutStore.responseData.booking ? `${window.location.origin}${url_booking}?calendar=${checkoutStore.responseData.calendar}&order_no=${checkoutStore.responseData.order_no}` : `${window.location.origin}${url_success}`,
|
|
289
329
|
receipt_email: inputData.value.email
|
|
290
330
|
}
|
|
291
331
|
});
|
|
292
332
|
if (error2.type === "card_error" || error2.type === "validation_error") {
|
|
293
333
|
showMessage(error2.message);
|
|
294
|
-
} else {
|
|
295
334
|
}
|
|
296
335
|
} else {
|
|
297
336
|
showMessage(error.message);
|
|
@@ -28,10 +28,8 @@ export default defineEventHandler(async (event) => {
|
|
|
28
28
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
29
29
|
}
|
|
30
30
|
});
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
await writeFile(filePath, JSON.stringify(banners, null, 2), "utf-8");
|
|
34
|
-
}
|
|
31
|
+
await ensureCacheDir();
|
|
32
|
+
await writeFile(filePath, JSON.stringify(banners, null, 2), "utf-8");
|
|
35
33
|
return banners;
|
|
36
34
|
} catch (error) {
|
|
37
35
|
throw createError({
|
|
@@ -45,10 +45,8 @@ export default defineEventHandler(async (event) => {
|
|
|
45
45
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
46
46
|
}
|
|
47
47
|
});
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
await writeFile(filePath, JSON.stringify(brand, null, 2), "utf-8");
|
|
51
|
-
}
|
|
48
|
+
await ensureCacheDir();
|
|
49
|
+
await writeFile(filePath, JSON.stringify(brand, null, 2), "utf-8");
|
|
52
50
|
return brand;
|
|
53
51
|
} catch (error) {
|
|
54
52
|
throw createError({
|
|
@@ -31,10 +31,8 @@ export default defineEventHandler(async (event) => {
|
|
|
31
31
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
32
32
|
}
|
|
33
33
|
});
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
await writeFile(filePath, JSON.stringify(categories, null, 2), "utf-8");
|
|
37
|
-
}
|
|
34
|
+
await ensureCacheDir();
|
|
35
|
+
await writeFile(filePath, JSON.stringify(categories, null, 2), "utf-8");
|
|
38
36
|
return categories;
|
|
39
37
|
} catch (error) {
|
|
40
38
|
throw createError({
|
|
@@ -31,10 +31,8 @@ export default defineEventHandler(async (event) => {
|
|
|
31
31
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
32
32
|
}
|
|
33
33
|
});
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
await writeFile(filePath, JSON.stringify(categories, null, 2), "utf-8");
|
|
37
|
-
}
|
|
34
|
+
await ensureCacheDir();
|
|
35
|
+
await writeFile(filePath, JSON.stringify(categories, null, 2), "utf-8");
|
|
38
36
|
return categories;
|
|
39
37
|
} catch (error) {
|
|
40
38
|
throw createError({
|
|
@@ -29,10 +29,8 @@ export default defineEventHandler(async (event) => {
|
|
|
29
29
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
30
30
|
}
|
|
31
31
|
});
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
await writeFile(filePath, JSON.stringify(featured, null, 2), "utf-8");
|
|
35
|
-
}
|
|
32
|
+
await ensureCacheDir();
|
|
33
|
+
await writeFile(filePath, JSON.stringify(featured, null, 2), "utf-8");
|
|
36
34
|
return featured;
|
|
37
35
|
} catch (error) {
|
|
38
36
|
throw createError({
|
|
@@ -32,10 +32,8 @@ export default defineEventHandler(async (event) => {
|
|
|
32
32
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
33
33
|
}
|
|
34
34
|
});
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
await writeFile(filePath, JSON.stringify(samples, null, 2), "utf-8");
|
|
38
|
-
}
|
|
35
|
+
await ensureCacheDir();
|
|
36
|
+
await writeFile(filePath, JSON.stringify(samples, null, 2), "utf-8");
|
|
39
37
|
return samples;
|
|
40
38
|
} catch (error) {
|
|
41
39
|
throw createError({
|
|
@@ -32,10 +32,8 @@ export default defineEventHandler(async (event) => {
|
|
|
32
32
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
33
33
|
}
|
|
34
34
|
});
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
await writeFile(filePath, JSON.stringify(search, null, 2), "utf-8");
|
|
38
|
-
}
|
|
35
|
+
await ensureCacheDir();
|
|
36
|
+
await writeFile(filePath, JSON.stringify(search, null, 2), "utf-8");
|
|
39
37
|
return search;
|
|
40
38
|
} catch (error) {
|
|
41
39
|
throw createError({
|
|
@@ -24,6 +24,7 @@ export default defineEventHandler(async (event) => {
|
|
|
24
24
|
const cacheKey = `${slug}-${JSON.stringify(query)}`;
|
|
25
25
|
const fileName = cacheKey.replace(/[^a-zA-Z0-9-_]/g, "_");
|
|
26
26
|
const filePath = join(CACHE_DIR, `${fileName}-${customerType}.json`);
|
|
27
|
+
console.log("CACHE_DIR", filePath);
|
|
27
28
|
try {
|
|
28
29
|
const fileContent = await readFile(filePath, "utf-8");
|
|
29
30
|
const category = JSON.parse(fileContent);
|
|
@@ -36,10 +36,8 @@ export default defineEventHandler(async (event) => {
|
|
|
36
36
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
await writeFile(filePath, JSON.stringify(blog, null, 2), "utf-8");
|
|
42
|
-
}
|
|
39
|
+
await ensureCacheDir();
|
|
40
|
+
await writeFile(filePath, JSON.stringify(blog, null, 2), "utf-8");
|
|
43
41
|
return blog;
|
|
44
42
|
} catch (error) {
|
|
45
43
|
throw createError({
|
|
@@ -22,10 +22,8 @@ export default defineEventHandler(async (event) => {
|
|
|
22
22
|
try {
|
|
23
23
|
const config = useRuntimeConfig();
|
|
24
24
|
const countries = await flowrixApi.get(`countries`, config);
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
await writeFile(filePath, JSON.stringify(countries, null, 2), "utf-8");
|
|
28
|
-
}
|
|
25
|
+
await ensureCacheDir();
|
|
26
|
+
await writeFile(filePath, JSON.stringify(countries, null, 2), "utf-8");
|
|
29
27
|
return countries;
|
|
30
28
|
} catch (error) {
|
|
31
29
|
throw createError({
|
|
@@ -1,2 +1,5 @@
|
|
|
1
|
-
declare const _default: import("h3").EventHandler<import("h3").EventHandlerRequest, Promise<
|
|
1
|
+
declare const _default: import("h3").EventHandler<import("h3").EventHandlerRequest, Promise<"site map" | {
|
|
2
|
+
success: boolean;
|
|
3
|
+
message: string;
|
|
4
|
+
}>>;
|
|
2
5
|
export default _default;
|
|
@@ -1,32 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
defineEventHandler,
|
|
3
|
-
setResponseStatus
|
|
4
|
-
setHeader
|
|
3
|
+
setResponseStatus
|
|
5
4
|
} from "h3";
|
|
6
|
-
import { useRuntimeConfig } from "#imports";
|
|
7
|
-
import { $fetch } from "ofetch";
|
|
8
5
|
export default defineEventHandler(async (event) => {
|
|
9
6
|
try {
|
|
10
|
-
|
|
11
|
-
if (fullPath.startsWith("/")) {
|
|
12
|
-
fullPath = fullPath.slice(1);
|
|
13
|
-
}
|
|
14
|
-
const isGzip = fullPath.endsWith(".gz");
|
|
15
|
-
const config = useRuntimeConfig();
|
|
16
|
-
const cdnUrl = config.public.FLOWRIX_CDN + fullPath;
|
|
17
|
-
const buffer = await $fetch(cdnUrl, { responseType: "arrayBuffer" });
|
|
18
|
-
const data = Buffer.from(buffer);
|
|
19
|
-
if (isGzip) {
|
|
20
|
-
setHeader(event, "Content-Type", "application/xml; charset=utf-8");
|
|
21
|
-
setHeader(event, "Content-Encoding", "gzip");
|
|
22
|
-
return data;
|
|
23
|
-
}
|
|
24
|
-
setHeader(event, "Content-Type", "application/xml; charset=utf-8");
|
|
25
|
-
return data.toString();
|
|
7
|
+
return "site map";
|
|
26
8
|
} catch (error) {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
return
|
|
30
|
-
<error>File not found</error>`;
|
|
9
|
+
console.error("File save error:", error);
|
|
10
|
+
setResponseStatus(event, 500);
|
|
11
|
+
return { success: false, message: "Failed to download or save files" };
|
|
31
12
|
}
|
|
32
13
|
});
|
|
@@ -36,10 +36,8 @@ export default defineEventHandler(async (event) => {
|
|
|
36
36
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
await writeFile(filePath, JSON.stringify(page, null, 2), "utf-8");
|
|
42
|
-
}
|
|
39
|
+
await ensureCacheDir();
|
|
40
|
+
await writeFile(filePath, JSON.stringify(page, null, 2), "utf-8");
|
|
43
41
|
return page;
|
|
44
42
|
} catch (error) {
|
|
45
43
|
throw createError({
|
|
@@ -34,10 +34,8 @@ export default defineEventHandler(async (event) => {
|
|
|
34
34
|
const product = await flowrixApi.post(`product/${slug}`, config, {
|
|
35
35
|
body: JSON.stringify(body)
|
|
36
36
|
});
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
await writeFile(filePath, JSON.stringify(product, null, 2), "utf-8");
|
|
40
|
-
}
|
|
37
|
+
await ensureCacheDir();
|
|
38
|
+
await writeFile(filePath, JSON.stringify(product, null, 2), "utf-8");
|
|
41
39
|
return product;
|
|
42
40
|
} catch (error) {
|
|
43
41
|
throw createError({
|
|
@@ -39,10 +39,8 @@ export default defineEventHandler(async (event) => {
|
|
|
39
39
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
40
40
|
}
|
|
41
41
|
});
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
await writeFile(filePath, JSON.stringify(service, null, 2), "utf-8");
|
|
45
|
-
}
|
|
42
|
+
await ensureCacheDir();
|
|
43
|
+
await writeFile(filePath, JSON.stringify(service, null, 2), "utf-8");
|
|
46
44
|
return service;
|
|
47
45
|
} catch (error) {
|
|
48
46
|
throw createError({
|
|
@@ -39,10 +39,8 @@ export default defineEventHandler(async (event) => {
|
|
|
39
39
|
"Origin": process.env.FLOWRIX_API_ORIGIN
|
|
40
40
|
}
|
|
41
41
|
});
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
await writeFile(filePath, JSON.stringify(service, null, 2), "utf-8");
|
|
45
|
-
}
|
|
42
|
+
await ensureCacheDir();
|
|
43
|
+
await writeFile(filePath, JSON.stringify(service, null, 2), "utf-8");
|
|
46
44
|
return service;
|
|
47
45
|
} catch (error) {
|
|
48
46
|
throw createError({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowrix",
|
|
3
|
-
"version": "1.0.1-beta.
|
|
3
|
+
"version": "1.0.1-beta.88",
|
|
4
4
|
"description": "Plug-and-play Nuxt eCommerce cart powered by FLOWRiX. Subscription required.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -40,16 +40,30 @@
|
|
|
40
40
|
"test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@nuxt/image": "1.11.0",
|
|
43
|
+
"@nuxt/image": "^1.11.0",
|
|
44
44
|
"@nuxt/kit": "4.2.0",
|
|
45
|
-
"@nuxtjs/seo": "3.2.2",
|
|
45
|
+
"@nuxtjs/seo": "^3.2.2",
|
|
46
46
|
"@pinia/nuxt": "0.7.0",
|
|
47
47
|
"@stripe/stripe-js": "8.2.0",
|
|
48
|
-
"@vueuse/nuxt": "14.0.0",
|
|
49
|
-
"nuxt-gtag": "4.1.0",
|
|
50
|
-
"nuxt-swiper": "2.0.1",
|
|
51
|
-
"nuxt-toast": "1.4.0",
|
|
48
|
+
"@vueuse/nuxt": "^14.0.0",
|
|
49
|
+
"nuxt-gtag": "^4.1.0",
|
|
50
|
+
"nuxt-swiper": "^2.0.1",
|
|
51
|
+
"nuxt-toast": "^1.4.0",
|
|
52
52
|
"pinia": "2.3.1",
|
|
53
|
-
"pinia-plugin-persistedstate": "3.2.3"
|
|
53
|
+
"pinia-plugin-persistedstate": "^3.2.3"
|
|
54
|
+
},
|
|
55
|
+
"devDependencies": {
|
|
56
|
+
"@nuxt/devtools": "2.6.5",
|
|
57
|
+
"@nuxt/eslint-config": "1.9.0",
|
|
58
|
+
"@nuxt/module-builder": "^1.0.2",
|
|
59
|
+
"@nuxt/schema": "4.2.0",
|
|
60
|
+
"@nuxt/test-utils": "3.19.2",
|
|
61
|
+
"@types/node": "24.9.1",
|
|
62
|
+
"changelogen": "0.6.2",
|
|
63
|
+
"eslint": "9.38.0",
|
|
64
|
+
"nuxt": "4.2.0",
|
|
65
|
+
"typescript": "5.9.3",
|
|
66
|
+
"vitest": "3.2.4",
|
|
67
|
+
"vue-tsc": "3.1.1"
|
|
54
68
|
}
|
|
55
69
|
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
defineEventHandler,
|
|
3
|
-
setResponseStatus,
|
|
4
|
-
setHeader
|
|
5
|
-
} from "h3";
|
|
6
|
-
import { useRuntimeConfig } from "#imports";
|
|
7
|
-
import { $fetch } from "ofetch";
|
|
8
|
-
export default defineEventHandler(async (event) => {
|
|
9
|
-
try {
|
|
10
|
-
const config = useRuntimeConfig();
|
|
11
|
-
const fileUrl = config.public.FLOWRIX_CDN + "robots.txt";
|
|
12
|
-
const fileContent = await $fetch(fileUrl);
|
|
13
|
-
setHeader(event, "Content-Type", "text/plain; charset=utf-8");
|
|
14
|
-
return fileContent;
|
|
15
|
-
} catch (error) {
|
|
16
|
-
setResponseStatus(event, 404);
|
|
17
|
-
setHeader(event, "Content-Type", "text/plain; charset=utf-8");
|
|
18
|
-
return `File not found`;
|
|
19
|
-
}
|
|
20
|
-
});
|