Darren R
Darren R
AAlokai
Created by Darren R on 7/27/2024 in #🙋|general-help
Where did the Nuxt 3 boilerplate go?
Hi @Inês Barros and @Mateusz Ostafil Thank you both for your replies. So to clarify for those of us who have projects on VSF 2 (Nuxt 2/Vue 2). Our options to upgrade so we can use Nuxt 3/Vue 3 are to either: 1. Pay for enterprise 2. Write our own Storefronts Is that accurate?
16 replies
AAlokai
Created by Darren R on 7/27/2024 in #🙋|general-help
Where did the Nuxt 3 boilerplate go?
It appears that Alokai have completely abandoned the community here. Has anyone tried any other communication channels to get an update from them?
16 replies
AAlokai
Created by Darren R on 7/27/2024 in #🙋|general-help
Where did the Nuxt 3 boilerplate go?
It would be great if someone from Alokai could clarify what is happening here. This lack of communication with the community is making me lose confidence in using any Alokai products.
16 replies
AAlokai
Created by CCavelier on 6/5/2024 in #🙋|general-help
buildModule with updated package
To fix that import error you need to import as type import type { SdkModuleOptions } from "./vsfModule"
6 replies
AAlokai
Created by CCavelier on 6/5/2024 in #🙋|general-help
buildModule with updated package
@CCavelier That overload error is because the BuildModule options expects a value for cdnCacheBustingId If you add it that error will resolve.
magento: buildModule(middlewareModule<Endpoints>, {
apiUrl: 'http://localhost:8181/magento',
cdnCacheBustingId: 'your-cdn-cache-busting-id',
}),

magento: buildModule(middlewareModule<Endpoints>, {
apiUrl: 'http://localhost:8181/magento',
cdnCacheBustingId: 'your-cdn-cache-busting-id',
}),

6 replies
AAlokai
Created by CyberPanda on 5/8/2024 in #🙋|general-help
Questions after Alokai rebranding
Hi @rohrig Would you advise we start with the generic Nuxt3 boilerplate you linked to above and ignore this one? https://github.com/TidycodeIT/nuxt3-magento-sdk-storefront
11 replies
AAlokai
Created by CyberPanda on 5/8/2024 in #🙋|general-help
Questions after Alokai rebranding
@Siber I have no new information. I get the impression that unless you go enterprise, support is now very limited. We have been using Vue Storefront 2 for a couple of years, but are really struggling to see a path forward with our projects using the Open Source solutions. Our current plan is to create our own Nuxt 3 storefront and use the Alokai Magento SDK to connect to Magento (although we might end up creating our own Middleware too).
11 replies
AAlokai
Created by CyberPanda on 5/8/2024 in #🙋|general-help
Questions after Alokai rebranding
@CyberPanda This thread might add some clarity: https://discord.com/channels/770285988244750366/1222864672273727559/1222933886456037446 It would be good if @rohrig could provide answers to the specific questions asked here though. I also have those same questions.
11 replies
AAlokai
Created by radhu on 3/18/2024 in #🙋|general-help
Magento 2 VSF: Customers are automatically logged out after a period of time.
@radhu What you have added will work when you hard reload the page. However, that onMounted hook will not run when navigating around the site using links. This might not be an issue for you, but if it is, you can use middleware to add that check/logout. This will run on every page change. https://v2.nuxt.com/docs/directory-structure/middleware/
8 replies
AAlokai
Created by radhu on 3/18/2024 in #🙋|general-help
Magento 2 VSF: Customers are automatically logged out after a period of time.
@radhu isAuthenticated is using the useUser composable. This is getting the value for the isAuthenticated from the Pinia storecustomerStore.isLoggedIn Clicking a logout on the front-end should run the logout function and clear the values in the CustomerStore. The token-expired plugin should also check on page refresh and reset the customerStore I've had a look at the logic in that plugin file and it looks like it should do ths if GraphQL is no longer authorized. Can you add logging in here to see if its actually trying to run any functions?
8 replies
AAlokai
Created by elvis_h on 3/21/2024 in #🙋|general-help
Use external component in vuestore front
@elvis_h You need to add this as a Nuxt plugin. Example here: https://debbie.codes/blog/nuxt-add-vue-plugins/
2 replies
AAlokai
Created by radhu on 3/18/2024 in #🙋|general-help
Magento 2 VSF: Customers are automatically logged out after a period of time.
Hi @radhu What is the expiry of the vsf-customer cookie that get's set when you log in? If this Cookie has expired VSF will log you out. Another reason you will get logged out is if the function in plugins/token-expired.ts does not find a Customer Token. According to the Adobe docs, the default Customer Token lifetime is set to 1 hour. Here is a link to the Adobe docs that may help: https://developer.adobe.com/commerce/webapi/graphql/usage/authorization-tokens/
8 replies
AAlokai
Created by Darren R on 2/7/2024 in #🙋|general-help
Canonical Links have forward slash encoded which breaks the page
Hi @skirianov After some digging I think this might be an issue with the Nuxt i18n module. I've raised an issue on Github for it: https://github.com/nuxt-modules/i18n/issues/2764
4 replies
AAlokai
Created by Darren R on 1/31/2024 in #🙋|general-help
GET error Error when product goes out of stock
It looks like the issue is VSF still gets through the route data based on the product url. This returns the sku/type. Because of this, it tries to render the Product page, but this throws an error. I think this is due to not being able to retrieve the product data correctly due to it not being active in Magento. In the product template it actually checks this product data and if we have no sku throws an error.
if (Boolean(product?.value?.sku) === false) {
nuxtError({ statusCode: 404 });
}
if (Boolean(product?.value?.sku) === false) {
nuxtError({ statusCode: 404 });
}
This didn't stop the rest of the fetch functions from trying to run though, which caused my issue (was a 500 error). I've added a return and this is working ok now.
if (Boolean(product?.value?.sku) === false) {
nuxtError({ statusCode: 404 });
return;
}
if (Boolean(product?.value?.sku) === false) {
nuxtError({ statusCode: 404 });
return;
}
It still loads the product page based on the route response, but now doesn't try to run all the fetch functions and renders the 404 template correctly.
3 replies
AAlokai
Created by Darren R on 1/24/2024 in #🙋|general-help
GraphQL queries are using POST, should be GET
I may be getting confused here. I'm looking at the network activity in the browser, where requests are getting sent via POST to /api/magento/... How can I verify the GraphQL queries that hit Magento are using GET
4 replies
AAlokai
Created by Caroline on 11/16/2023 in #🙋|general-help
Remove google recaptcha from login modal
@Caroline I'm not sure you can overwrite just that one function and overwriting the full file wouldn't be ideal. We turned off the recaptcha in our env and then used HTTP headers on the queries we wanted protecting: https://developer.adobe.com/commerce/webapi/graphql/usage/protected-mutations/
11 replies
AAlokai
Created by Caroline on 11/16/2023 in #🙋|general-help
Remove google recaptcha from login modal
It looks like setting it to true in env will enable for all the supported queries and you cannot turn off for just one (generateCustomerToken) as it's in the middleware.
11 replies
AAlokai
Created by Caroline on 11/16/2023 in #🙋|general-help
Remove google recaptcha from login modal
You're right. I just looked in node_modules/@vue-storefront/magento-api/lib/index.server.js and it's checking config.recaptcha.isEnabled directly there.
11 replies
AAlokai
Created by Caroline on 11/16/2023 in #🙋|general-help
Remove google recaptcha from login modal
@Caroline You could try overriding the global config setting that LoginModal.vue is using.
const isRecaptchaEnabled = ref<boolean>(typeof $recaptcha !== 'undefined' && Boolean($config.isRecaptcha));
const isRecaptchaEnabled = ref<boolean>(typeof $recaptcha !== 'undefined' && Boolean($config.isRecaptcha));
The above is using your value from env, just set it to false and then it shouldn't be used for the Login.
const isRecaptchaEnabled = ref(false)
const isRecaptchaEnabled = ref(false)
11 replies
AAlokai
Created by Darren R on 9/21/2023 in #🙋|general-help
generateCustomerToken api has customQuery param missing in the latest version
@rohrig That's great, thanks!
28 replies