https://github.com/alexwayfer/flame-r18n
R18n helper for Flame
https://github.com/alexwayfer/flame-r18n
flame flame-plugin i18n internationalization r18n ruby
Last synced: about 1 year ago
JSON representation
R18n helper for Flame
- Host: GitHub
- URL: https://github.com/alexwayfer/flame-r18n
- Owner: AlexWayfer
- License: mit
- Created: 2016-05-19T14:52:31.000Z (about 10 years ago)
- Default Branch: main
- Last Pushed: 2025-04-04T12:46:07.000Z (about 1 year ago)
- Last Synced: 2025-04-09T22:08:45.120Z (about 1 year ago)
- Topics: flame, flame-plugin, i18n, internationalization, r18n, ruby
- Language: Ruby
- Homepage:
- Size: 137 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Flame R18n
Flame plugin which provides
[i18n and L10n](https://en.wikipedia.org/wiki/Internationalization_and_localization) support
to your web application.
It is a wrapper for [R18n core library](https://github.com/r18n/r18n-core).
See [R18n documentation](https://github.com/r18n/r18n-core/blob/main/README.md)
for more information.
[](https://cirrus-ci.com/github/AlexWayfer/flame-r18n)
[](https://codecov.io/gh/AlexWayfer/flame-r18n)
[](https://codeclimate.com/github/AlexWayfer/flame-r18n)

[](https://inch-ci.org/github/AlexWayfer/flame-r18n)
[](https://github.com/AlexWayfer/flame-r18n/blob/main/LICENSE.txt)
[](https://rubygems.org/gems/flame-r18n)
## Usage
```ruby
# Gemfile
gem 'flame-r18n'
# config.ru
require 'flame-r18n' # or `Bundler.require`
# For application configuration
# config/processors/r18n.rb
::R18n.default_places = File.join config[:root_dir], 'locales'
::R18n::I18n.default = 'en'
# _controller.rb
include Flame::R18n::Initialization # for loading thread-based locale
# site/_controller.rb
prepend Flame::R18n::LocaleInPath # for mounting controllers at `/:locale`
```
## Development
After checking out the repo, run `bundle install` to install dependencies.
Then, run `toys rspec` to run the tests.
To install this gem onto your local machine, run `toys gem install`.
To release a new version, run `toys gem release %version%`.
See how it works [here](https://github.com/AlexWayfer/gem_toys#release).
## Contributing
Bug reports and pull requests are welcome on [GitHub](https://github.com/AlexWayfer/flame-r18n).
## License
The gem is available as open source under the terms of the
[MIT License](https://opensource.org/licenses/MIT).