Giter Club home page Giter Club logo

spree_i18n's Introduction

Spree Internationalization

Build Status Code Climate

This is the Internationalization project for Spree Commerce

See the official Internationalization documentation for more details.

Happy translating!


  1. Add this extension to your Gemfile with this line:

Spree >= 3.1

gem 'spree_i18n', github: 'spree-contrib/spree_i18n'

Spree 3.0 and Spree 2.x

gem 'spree_i18n', github: 'spree-contrib/spree_i18n', branch: 'X-X-stable'

The branch option is important: it must match the version of Spree you're using. For example, use 3-0-stable if you're using Spree 3-0-stable or any 3.0.x version.

  1. Install the gem using Bundler:
bundle install
  1. Copy & run migrations
bundle exec rails g spree_i18n:install
  1. Restart your server

If your server was running, restart it so that it can find the assets properly.


Model Translations

We removed support for translating models into a separate Gem.

Please update your Gemfile if you still need the model translations.

# Gemfile
gem 'spree_globalize', github: 'spree-contrib/spree_globalize', branch: 'master'

Upgrading

WARNING: If you want to keep your model translations, be sure to add the spree_globalize gem to your Gemfile before migrating the database. Otherwise you will loose your translations!

1. Migrate your database

bin/rake spree_i18n:upgrade
bin/rake db:migrate

Note: The migration automatically skips the removal of the translations tables. So it's safe to run the migration without data loss. But be sure to have the spree_globalize gem in your Gemfile, if you want to keep them.

2. Remove Assets

From vendor/assets/javascripts/spree/backend/all.js

//= require spree/backend/spree_i18n

and from vendor/assets/stylesheets/spree/backend/all.css

*= require spree/backend/spree_i18n

3. Remove Configuration

Remove all occurrences of SpreeI18n::Config.supported_locales from your code.


Contributing

See corresponding guidelines


Copyright (c) 2010-2015 Spree Commerce Inc. and other contributors. released under the New BSD License

spree_i18n's People

Contributors

adhlssu07 avatar alepore avatar camelmasa avatar cbilgili avatar daan- avatar damianlegawiec avatar futhr avatar geekoncoffee avatar greendog avatar hnatt avatar huoxito avatar igmarin avatar j15e avatar jdutil avatar jpavello avatar kagetsuki avatar mamhoff avatar maxim-filimonov avatar peterberkenbosch avatar pszyszkaspark avatar pusewicz avatar radar avatar reinaris avatar romul avatar sadfuzzy avatar schof avatar tka avatar tobiashm avatar tvdeyen avatar zubietaroberto avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.