Skip to content
This repository has been archived by the owner on Apr 18, 2023. It is now read-only.

Internalize pluralization #161

Merged
merged 1 commit into from
Oct 20, 2014
Merged

Internalize pluralization #161

merged 1 commit into from
Oct 20, 2014

Conversation

jamesarosen
Copy link
Owner

  • remove dependency on CLDR.js
  • add lib/i18n-plurals.js with pluralization logic, to be included after lib/i18n.js
  • add deprecation warning if window.CLDR is defined
  • look for current locale in Ember.I18n.currentLocale before falling back on CLDR.defaultLanguage
  • Change README to describe new process to add pluralization support

Closes #46

See also #49

@jamesarosen jamesarosen added this to the v2.9 milestone Oct 20, 2014
@jamesarosen
Copy link
Owner Author

@pjmorse this is one of the big ones for 2.9

@pjmorse
Copy link
Collaborator

pjmorse commented Oct 20, 2014

OK. I'll give it some chewing.

@@ -33,7 +35,7 @@
'az', 'bm', 'my', 'zh', 'dz', 'ka', 'hu', 'ig', 'id', 'ja', 'jv', 'kea',
'kn', 'km', 'ko', 'ses', 'lo', 'kde', 'ms', 'fa', 'root', 'sah', 'sg',
'ii', 'th', 'bo', 'to', 'tr', 'vi', 'wo', 'yo'
], function(n) {
], function(/* n */) {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just to make JSHint happy.

@jamesarosen jamesarosen force-pushed the james/internalize-plurals branch 2 times, most recently from 7af5ed4 to 1f16dc9 Compare October 20, 2014 16:20
@@ -25,6 +25,7 @@ test: development_dependencies
@./script/run.js

vendor_install: development_dependencies
@mkdir -p ./vendor
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Travis build was breaking. I thought Travis was trolling me with some weird connectivity problem. It turns out vendor/ isn't in the git repo now that I removed vendor/cldr.js.

@pjmorse
Copy link
Collaborator

pjmorse commented Oct 20, 2014

Looks good so far. I'm going to spin up a quick demo app to make myself more confident.

@pjmorse
Copy link
Collaborator

pjmorse commented Oct 20, 2014

Aside from the backwards-compatibility thing, this looks 👍 to me.

 * remove dependency on `CLDR.js`
 * add `lib/i18n-plurals.js` with pluralization logic, to be included
   after `lib/i18n.js`
 * add deprecation warning if `window.CLDR` is defined
 * look for current locale in `Ember.I18n.currentLocale` before
   falling back on `CLDR.defaultLanguage`
 * Change README to describe new process to add pluralization
   support

Closes #46

See also #49
jamesarosen added a commit that referenced this pull request Oct 20, 2014
@jamesarosen jamesarosen merged commit 36298ab into master Oct 20, 2014
@jamesarosen jamesarosen deleted the james/internalize-plurals branch October 20, 2014 18:36
@jamesarosen
Copy link
Owner Author

@pjmorse Now that this is merged, v2.9 has no remaining items. I propose that I

  1. bump the version to 2.9.0
  2. create a tag and a release
  3. create a v2-stable branch
  4. start breaking compatibility!

Is there anything else you think we should get in before that?

@pjmorse
Copy link
Collaborator

pjmorse commented Oct 20, 2014

No, I think that's a good plan. I can imagine #149 going in on the v2-stable branch - that seems broadly useful to people who aren't on a new enough Ember version to need 3.x - but that shouldn't stop you tagging, releasing, and starting on the 3.0 tasks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Include CLDR pluralization in this library
2 participants