Skip to content

What's the purpose of i18n folder and more #622

Answered by Sp-cy
96312 asked this question in Q&A
Discussion options

You must be logged in to vote

I made my AI chat assistant give a better explanation:

The i18n folder in Hugo is used to store localized versions of your website. It contains subfolders for each language that you want to support, and within those subfolders are the translated content files.

When a user visits your website with a specific language code (e.g. en, fr, de), Hugo will look in the i18n folder for the corresponding language's version of the content file, and serve that to the user instead of the default English version. This allows you to create a multilingual website that is accessible to users who speak different languages.

For example, if your website has a page called "About Us", you might have an i18n/en

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@Sp-cy
Comment options

Answer selected by 96312
@96312
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants