Skip to content

Repository files navigation

Gettext Json format

Latest Version on PackagistSoftware LicenseBuild StatusQuality ScoreTotal Downloads

Created by Oscar Otero http://oscarotero.comoom@oscarotero.com (MIT License)

Json loader and generator to use with gettext/gettext

Installation

composer require gettext/json

Usage example

useGettext\Loader\PoLoader;
useGettext\Loader\JsonLoader;
useGettext\Generator\JsonGenerator;
useGettext\Translations;
//Load a .po file and export to .json$translations = (newPoLoader())->loadFile('locales/translations.po');
(newJsonGenerator())->generateFile($translations, 'locales/translations.json');
//You can load the json file with JsonLoader$loadedTranslations = (newJsonLoader())->loadFile('locales/translations.json');

Please see CHANGELOG for more information about recent changes and CONTRIBUTING for contributing details.

The MIT License (MIT). Please see LICENSE for more information.

About

Json format for gettext

Topics

Resources

Contributing

Stars

6 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages