<commit_before>= RailsI18nRoutes

This project rocks and uses MIT-LICENSE.<commit_msg>Rdoc documentation<commit_after>= Rails I18n Routes

Adds handy methods to ActionDispatch to deal with translations.

= Install

Put this line in your Gemfile:
  gem 'rails-i18n-routes', :git => '<EMAIL>:mattways/rails-i18n-routes.git'
  
Then bundle:
  $ bundle  
  
= Usage

Choose how the language would be selected in your application.rb...

To use prefix (default):
  config.i18n_routes.selection = :prefix

To use subdomain:
  config.i18n_routes.selection = :subdomain
  config.i18n_routes.mapping = {
    :es => [:ar, :uy]
    :pt => [:br]
  }

In the case of subdomains you need to name the yml file in your locales dir using this format:
  es_uy.yml
  es_ar.yml
  pt_br.yml
  
Finally in your routes.rb pass the routes you want to be localized to localize method:
  localize do
    math 'contact' => 'static#contact', :as => 'contact'
  end
{'fraction_non_alphanumeric': 0.09304812834224599, 'fraction_numerical': 0.014973262032085561, 'mean_word_length': 3.751269035532995, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3978951', 'n_tokens_mistral': 328, 'n_tokens_neox': 312, 'n_words': 108}