Localization files for Snipcart shopping cart v2.
Use locales/en.js
as the reference file. Fork and send a pull request.
Contact us at [email protected]
if you have questions or comments.
Localization files for Snipcart's shopping cart v2
Home Page: https://docs.snipcart.com/v2/configuration/localization
License: MIT License
Localization files for Snipcart shopping cart v2.
Use locales/en.js
as the reference file. Fork and send a pull request.
Contact us at [email protected]
if you have questions or comments.
Some texts are not localized and I don't find their entries in this repository.
Page « My orders »:
Page « My profile »:
I might discover more as I start playing around with Snipcart.
I have changed language from en
to de
. I am following each step given here. Every time on loading page I get warning messages in my console.
Around the bottom of the file there's some string weirdness turning object keys into strings
I have changed language from en
to de
. I have done all the configurations given in "Snipcart Documentation". But I am still getting warnings in logs whenever the page is reloaded.
<html lang="de">
in "de.js" file the code looks something like this
Snipcart.execute('bind', 'app.ready', function () {
Snipcart.execute('registerLocale', 'de', {
first_name: "Vorname",
last_name: "Nachname",
........................
How can I prevent this warnings?
We plan to use Snipcart and currently, we try it. But it's appear the debug messages are not relevant. We need a strong debug message system during development phase to be able to do the maximum things without help. So, maybe is just a lack in documentation or me which is not implement my test in a correct way. This is my problem :
I have already read some closed issue and I know there is a way to disable debug message like this :
<script>
document.addEventListener('snipcart.ready', function() {
Snipcart.DEBUG = false;
});
</script>
It's seems some debug messages not reflect what is actually done.
Below, this is my started implementation:
<!DOCTYPE html>
<html lang="fr-fr" class="min">
<head>
<!-- meta -->
<link href="https://cdn.snipcart.com/themes/2.0/base/snipcart.min.css" type="text/css" rel="stylesheet" />
</head>
<body>
<!-- content -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.2/jquery.min.js"></script>
<script src="https://cdn.snipcart.com/scripts/2.0/snipcart.js" id="snipcart" data-api-key="NzJhNzMwMWEtMjQwMi00Y2Q0LWI0YmUtNTRkMzg4OTBmYWU1NjM2MzY4MjI5NTI5MzcxMjY4" data-autopop="false"></script>
<script type="text/javascript" src="scripts/fr-FR.js"></script>
</body>
</html>
All files provide a 200 status message and scripts/fr-FR.js
contain your current repository locales/fr-FR.js
file.
So currently my console show me this.
Snipcart: Locale fr not found, falling back to en
snipcart.js:8 Snipcart: Missing localization string bill_me_later_action for locale fr
snipcart.js:8 Snipcart: Missing localization string pay_via_mollie for locale fr
snipcart.js:8 Snipcart: Missing localization string pay_now_via_mollie for locale fr
snipcart.js:8 Snipcart: Missing localization string pay_via_mollie_explanation for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_status for locale fr
snipcart.js:8 Snipcart: Missing localization string errors_passwords_dont_match for locale fr
snipcart.js:8 Snipcart: Missing localization string error_discounts_have_expired for locale fr
snipcart.js:8 Snipcart: Missing localization string subscriptions_history_no_subscriptions for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_pause_button for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_failed_text for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_willbepaidlater for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_paypal for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_none for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_sofort for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_ideal for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_mistercash for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_banktransfer for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_directdebit for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_belfius for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_bitcoin for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_podiumcadeaukaart for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_paysafecard for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_bancontact for locale fr
snipcart.js:8 Snipcart: Missing localization string payment_method_creditcard for locale fr
snipcart.js:8 Snipcart: Missing localization string error_item_stock_exceeded for locale fr
snipcart.js:8 Snipcart: Missing localization string error_item_out_of_stock_text for locale fr
snipcart.js:8 Snipcart: Missing localization string item_out_of_stock_with_variant for locale fr
snipcart.js:8 Snipcart: Missing localization string something_went_wrong_while_fetching_rates for locale fr
snipcart.js:8 Snipcart: Missing localization string error_must_select_shipping_rate for locale fr
snipcart.js:8 Snipcart: Missing localization string manage_subscriptions for locale fr
snipcart.js:8 Snipcart: Missing localization string back_to_subscriptions_list for locale fr
snipcart.js:8 Snipcart: Missing localization string back_to_subscription_details for locale fr
snipcart.js:8 Snipcart: Missing localization string notifications_item_not_modified_due_to_min_quantity for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_resume_buttom for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_summary for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_notifications_paused for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_notifications_pause_confirm for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_notifications_resume_confirm for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_status_canceled for locale fr
snipcart.js:8 Snipcart: Missing localization string subscription_status_paused for locale fr
I have translated all labels not provided from fr-FR.js
and I provide it in this PR : #53
What I expected to see was this :
Snipcart: Locale fr not found, falling back to en
but console show all messages.
I had this code to wait the API is loading...
Snipcart.execute('app.ready', function () {
Snipcart.execute('registerLocale', 'fr-FR', {
...
});
});
What I expected to see was no messages anymore.
but console show all messages with this additional message:
...
Snipcart: Command app.ready not recognized
Hurray ! It's seems debug message work a little bit...
Snipcart.execute('bind', 'app.ready', function () {
Snipcart.execute('registerLocale', 'fr-FR', {
...
});
});
Using this alternative code the previous Snipcart: Command app.ready not recognized
is not display animore.
So what I expected is to see no error message anymore and all messages are always displayed.
So currently, your error message are not correct because the first message is
Snipcart: Locale fr not found, falling back to en
And
— I try to load fr-FR
(not some fr
)
— My app is currently in French exactly as I expected. So it's just the debug message was not relevant.
Then, the rest of message are not correct either because my file is up-to-date : #53
You can test that to go at https://blog.lesieur.name/espace-membres/
. Just open console with F12 and see the not relevant message. Test to open interface to see it in french.
What I'm doing wrong ?
Thanks !
The only thing missing is the localization for the countries in the dropdown for the Selection of country of residence.
I guess you're basing your list on a list of some standardized country codes like http://en.wikipedia.org/wiki/ISO_3166-1
Are you planning to integrate localizations for country names as well?
Let me know if you need a helping hand.
Hi there
I am translating the locales to german and there is a string that is unclear:
bill_me_later_explanation
Uses "receipt" in the english file but "facture" in the french, which if I'm not mistaken translates to "invoice". which one do you mean?
Thanks for your feedback
Greetings from Switzerland
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.