You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 20, 2023. It is now read-only.
At the moment the request to the cart.js doesn't fetch the translated content of the products such as the title.
Would it be possible to prefix the request url with the current root url?
For example when you translate your shop to French the root url will be /fr.
The ajax request to /cart.js fetches the products in the default language.
The products will be translated when you change the request to /fr/cart.js.
We’ve implemented this in our theme by setting the current cart routes on a global theme object in theme.liquid and reading them in this script, like this:
At the moment the request to the cart.js doesn't fetch the translated content of the products such as the title.
Would it be possible to prefix the request url with the current root url?
For example when you translate your shop to French the root url will be /fr.
The ajax request to
/cart.js
fetches the products in the default language.The products will be translated when you change the request to
/fr/cart.js
.As a side note this should be mentioned in the docs as well:
https://shopify.dev/docs/themes/ajax-api/reference/cart
The text was updated successfully, but these errors were encountered: