@@ -121,7 +121,7 @@ exports.$interpolate = function (text) {
var vm = this
if (tokens) {
if (tokens.length === 1) {
- return vm.$eval(tokens[0].value)
+ return vm.$eval(tokens[0].value) + ''
} else {
return tokens.map(function (token) {
return token.tag
@@ -151,6 +151,7 @@ describe('Data API', function () {
it('$interpolate', function () {
expect(vm.$interpolate('abc')).toBe('abc')
+ expect(vm.$interpolate('{{a}}')).toBe('1')
expect(vm.$interpolate('{{a}} and {{a + b.c | double}}')).toBe('1 and 6')
})