my-project/
└── config/
├── _default/
│ ├── hugo.toml
│ ├── menus.en.toml
│ ├── menus.de.toml
│ ├── languages.toml
│ └── params.toml
or
my-project/
└── config/
├── _default/
│ ├── hugo.toml
│ ├── menus.en.toml
│ ├── menus.de.toml
│ ├── languages
│ │ ├── en.toml
│ │ └── de.toml
│ └── params.toml
or any way for seperate params folder for each lanaguage.
Tell me the best and easiest way to manage lanaguages. Because there will be more than 20 languages
yousafblogger:
best and easiest
I think this will vary by project, but here’s one way to do it…
https://gohugo.io/configuration/introduction/#recursive-parsing
config/
└── _default/
├── foo/
│ ├── bar/
│ │ ├── menus.en.toml
│ │ ├── params.en.toml
│ │ └── taxonomies.en.toml
│ └── baz/
│ ├── menus.de.toml
│ ├── params.de.toml
│ └── taxonomies.de.toml
├── hugo.toml
└── languages.toml
In the above I have intentionally used foo
, bar
, and baz
to illustrate that those subdirectory names are irrelevant when Hugo recursively parses the config
directory. This does exactly the same thing:
config/
└── _default/
├── languages/
│ ├── de/
│ │ ├── menus.de.toml
│ │ ├── params.de.toml
│ │ └── taxonomies.de.toml
│ └── en/
│ ├── menus.en.toml
│ ├── params.en.toml
│ └── taxonomies.en.toml
├── hugo.toml
└── languages.toml
system
Closed
April 10, 2025, 3:05pm
3
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.