Create PO-files
There are many ways to create PO-files. But I decided to make it manually to begin with. Using Google Translate as a first step.
1. Create the file structure on your computer.
You can put the folder "locale" where you want, but I found it more convinient to use the public folder
go/
└── main/
├── public/
│ ├── css/
│ ├── js/
│ ├── img/
│ ├── locale/
│ │ ├── es.po
│ │ ├── de.po
│ │ ├── it.po
│ │ ├── sv.po
│ │ ├── en.po
│ │ └── ...
│ ├── misc/
│ └── html/
├── main.go
├── go.mod
└── go.sum
2. Create each language PO-file like this
A po file is a simple key(msgid) value(msgstr) file. This is an example of es.po.
msgid "Company" msgstr "Nagocio" msgid "home" msgstr "inicio" msgid "Create PO-files" msgstr "Crea file PO" msgid "Go Code" msgstr "Codice Go" msgid "HTML" msgstr "HTML"