Skip to content

Instantly share code, notes, and snippets.

@jcieslar
Last active August 29, 2015 14:23
Show Gist options
  • Save jcieslar/55f642b1f717cbf1eabe to your computer and use it in GitHub Desktop.
Save jcieslar/55f642b1f717cbf1eabe to your computer and use it in GitHub Desktop.
Angular i18n locale currency pain and how to setup with rails
= javascript_include_tag I18n.locale.to_s
%span.value {{ amount || 0 | currency:'$' }}
# I18n.locale => en
# => $100
# I18n.locale => pl
# => 100 $
#= require angular-i18n/angular-locale_en-us.js
gem 'rails-assets-angular-i18n', '~> 1.4.1'
#= require angular-i18n/angular-locale_pl-pl.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment