Package Data | |
---|---|
Maintainer Username: | jeroenbourgois |
Maintainer Contact: | hello@jackjoe.be (Jack + Joe) |
Package Create Date: | 2015-03-17 |
Package Last Update: | 2019-10-01 |
Home Page: | |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-22 15:00:35 |
Package Statistics | |
---|---|
Total Downloads: | 24,255 |
Monthly Downloads: | 60 |
Daily Downloads: | 3 |
Total Stars: | 1 |
Total Watchers: | 4 |
Total Forks: | 2 |
Total Open Issues: | 0 |
This package uses Symfony/Yaml parser, and is forked from Devitek/laravel-yaml-translation
Add Laravel Localization to your composer.json
file.
"jackjoe/yaml-translation": "*"
Run composer install
to get the latest version of the package.
It's recommended that you use Composer, however you can download and install from this repository.
You have to replace
'Illuminate\Translation\TranslationServiceProvider',
with
'JackJoe\Core\Translation\TranslationServiceProvider',
in config/app.php
.
Instead of using the regular php files to input your translation, use yml or yaml files instead.
PHP:
<?php
return [
'hello' => 'Hello :name',
'author' => 'Devitek',
];
Will in YAML be equivalent to:
hello: Hello :name
author: Jack + Joe
A more complex example:
title: My Website
copyright: |
2015 ©
team:
- name: Foo
age: 18
- name: Bar
age: 20
When you want to use the yaml
files, be sure to delete the php
files!
Copyright © 2018 Jack + Joe. This is free software, and may be redistributed under the terms specified in the LICENSE file.