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

fixes ng-pluralize when $interpolate is using non-standard start/end symbols #1169

Closed
wants to merge 1 commit into from

Conversation

btford
Copy link
Contributor

@btford btford commented Jul 19, 2012

Addresses issue #1134

@@ -182,7 +182,8 @@ var ngPluralizeDirective = ['$locale', '$interpolate', function($locale, $interp

forEach(whens, function(expression, key) {
whensExpFns[key] =
$interpolate(expression.replace(BRACE, '{{' + numberExp + '-' + offset + '}}'));
$interpolate(expression.replace(BRACE, $interpolate.startSymbol() + numberExp + '-' +
Copy link
Contributor

Choose a reason for hiding this comment

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

perf improvement: create temp variables for the start and end symbols outside of the forEach, preferably in the factory fn. then use those here.

@btford
Copy link
Contributor Author

btford commented Aug 8, 2012

@IgorMinar, I've made the appropriate fixes. Anything else?

@IgorMinar
Copy link
Contributor

the development of this fix has moved to PR #1256

@IgorMinar IgorMinar closed this Aug 13, 2012
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.

2 participants