0

i've this:

            $('input#tags_watch').typeahead({
                highlight: true,
                autoselect: true
            },
            {
                source: names.ttAdapter(),
                displayKey: 'name',
                templates: {
                    suggestion: Handlebars.compile([
                      '<div id="{{id}}"><p class="repo-country">{{country}}</p>',
                      '<p class="repo-name">{{name}}</p>',
                      '<p class="repo-city">{{city}} - {{ocupation}}</p></div>'
                    ].join(''))
                }
            });

it's allways returning an error: Uncaught Error: missing input

i don't know why this happens, but the input exists!!!

JS FIDDLE: http://jsfiddle.net/jhogLbg5/

Severiano
  • 1,083
  • 3
  • 25
  • 54

2 Answers2

0

This particular error is one annoying fact about V8. In most cases your JavaScript is broken in some way. For example missing a } or something like that.

Example given, this will yield "Unexpected missing input" too:

eval('[{"test": 4}') // notice the missing ]
munsifali
  • 1,732
  • 2
  • 24
  • 43
0

Re-downloaded the handlebars.js, problem solved

Severiano
  • 1,083
  • 3
  • 25
  • 54