vue-i18n-extract icon indicating copy to clipboard operation
vue-i18n-extract copied to clipboard

Gettext (.po file) support

Open gekkedev opened this issue 4 years ago • 1 comments

When trying to read .po-based language files, I run into a SyntaxError: Unexpected string based on this call (in an else-closure): https://github.com/pixari/vue-i18n-extract/blob/1ed4c301636c73cd0cc32e94109bc7e02d7880e6/src/create-report/language-files.ts#L33 It looks like there is no support for Gettext / .po fles has been implemented. Could this be achieved by using a loader like @openculinary/i18next-gettext-loader? Would love to see this file format supported.

To reproduce:

  1. create a Vue project using gettext
  2. install this CLI tool
  3. run npx vue-i18n-extract --languageFiles (json|yaml|yml|po) --vueFiles (your|file|matcher) (essentially adding po files into the Glob pattern)

gekkedev avatar Dec 02 '21 18:12 gekkedev

We're open to a PR that adds .po support, but it's outside the scope for the contributors of the project right now! Sorry!

Spittal avatar Apr 27 '22 16:04 Spittal