We have another page in Arabic. Would you like to change languages?
لدينا صفحة أخرى باللغة العربية. هل ترغب في تغيير اللغة؟
Yes / نعم No / لا
We have another page in Bengali. Would you like to change languages?
আমাদের কাছে বাংলা ভাষায় একটি অন্য পৃষ্ঠা আছে। আপনি কি ভাষা পরিবর্তন করতে চান?
Yes / হ্যাঁ No / না
We have another page in German. Would you like to change languages?
Wir haben eine weitere Seite auf Deutsch. Möchten Sie die Sprache wechseln?
Yes / Ja No / Nein
We have another page in Greek. Would you like to change languages?
Έχουμε άλλη μια σελίδα στα Ελληνικά. Θα θέλατε να αλλάξετε γλώσσα;
Yes / Ναι No / Όχι
We have another page in Spanish. Would you like to change languages?
Tenemos otra página en Español. ¿Te gustaría cambiar de idioma?
Yes / Sí No / No
We have another page in French. Would you like to change languages?
Nous avons une autre page en français. Voulez vous changer de langue ?
Yes / Oui No / Non
We have another page in Hindi. Would you like to change languages?
हमारे पास हिन्दी में एक और पृष्ठ है। क्या आप भाषाएँ बदलना चाहेंगे?
Yes / हाँ No / नहीं
We have another page in Hungarian. Would you like to change languages?
Van egy másik oldalunk magyarul. Szeretnél nyelvet változtatni?
Yes / Igen No / Nem
We have another page in Bahasa Indonesia. Would you like to change languages?
Kami memiliki halaman lain dalam Bahasa Indonesia. Apakah Anda ingin mengganti bahasa?
Yes / Ya No / Tidak
We have another page in Italian. Would you like to change languages?
Abbiamo un'altra pagina in Italiano. Ti piacerebbe cambiare lingua?
Yes / sì No / No
We have another page in Japanese. Would you like to change languages?
他のページが日本語にあります。言語を変更しますか?
Yes / はい No / いいえ
We have another page in Korean. Would you like to change languages?
우리는 또 다른 페이지가 한국어로 있습니다. 언어를 변경하시겠습니까?
Yes / 네 No / 아니요
We have another page in Dutch. Would you like to change languages?
We hebben nog een pagina in het Nederlands. Wilt u van taal veranderen?
Yes / Ja No / Nee
We have another page in Punjabi. Would you like to change languages?
ਸਾਡੇ ਕੋਲ ਇੱਕ ਹੋਰ ਪੰਨਾ ਹੈ ਪੰਜਾਬੀ ਵਿੱਚ। ਕੀ ਤੁਸੀਂ ਭਾਸ਼ਾ ਬਦਲਨਾ ਚਾਹੁੰਦੇ ਹੋ?
Yes / ਹਾਂ No / ਨਹੀਂ
We have another page in Polish. Would you like to switch languages?
Mamy inną stronę w języku polskim. Czy chciałbyś zmienić język?
Yes / Tak No / Nie
We have another page in Portuguese. Would you like to change languages?
Temos outra página em Português. Você gostaria de mudar de idioma?
Yes / Sim No / Não
We have another page in Russian. Would you like to change languages?
У нас есть другая страница на русском. Вы хотите изменить язык?
Yes / Да No / Нет
We have another page in Thai. Would you like to change languages?
เรามีอีกหน้าหนึ่งเป็นภาษาไทย คุณต้องการเปลี่ยนภาษาไหม?
Yes / ใช่ No / ไม่
We have another page in Turkish. Would you like to change languages?
Başka bir sayfamız Türkçe var. Dili değiştirmek ister misiniz?
Yes / Evet No / Hayır
We have another page in Vietnamese. Would you like to change languages?
Chúng tôi có một trang khác bằng Tiếng Việt. Bạn có muốn đổi ngôn ngữ không?
Yes / Có No / Không
We have another page in Chinese. Would you like to change languages?
我们有另一页是中文。您想要更改语言吗?
Yes / 是的 No / 不
Translations
A huge part of this project is support for translations.
It is integrated into many parts of the process.
The standard way to specify a string in HTML is like this: ${i18Next.t("Text to translate")}.
Once a translation is defined using i18Next, there are 3 potential ways the translation can be handled.
-
Manual -
The locale files (*.json files) are updated with the keys to translate and [[ and ]] surrounding them. This is intended to allow manual translation how you like. You can also use the prompt "translateManualFile.md" to help.
-
GoogleTranslate -
This uses the Google Translate API to translate items. This tends to be one of the cheaper and more reliable options I've seen. The only limitation I've run into is that it doesn't handle different plural forms well. So you may need to use OpenAI or Manual for anything that uses i18Next's pluralization feature.
-
OpenAI -
This uses the OpenAI API to translate items. This is the most expensive option I've seen. It is also the most flexible. It can handle different plural forms well. It can also handle more complex sentences. It is also the most likely to be able to handle new languages.
The setting for which translation to use is defined in your build.ts and the translationSource property for the staticSiteBuild call.