SpeakEasy! Please Help


#1



Cant get voice commands to work Confused about step four.


var template = function(text) {
  return '<p><input type="checkbox"><i class="glyphicon glyphicon-star"></i><span>' + text + '</span><i class="glyphicon glyphicon-remove"></i></p>';
};

var main = function() {
  $('form').submit(function() {
      var text=$('#todo').val();
      var html = template(text);
    	$('.list').append(html);
    	$('#todo').val("");
    
    
    return false;  
  });
  $(document).on('click','.glyphicon-star',function() {
    $(this).toggleClass('active');
  });
  $(document).on('click','.glyphicon-remove',function() {
    $(this).parent().remove();
  });
  
  if (annyang) {
  	var commands = {
      'add *item': add, 
    }; 
    annyang.addCommands(commands);
    annyang.start(); 
  };
  
};


$(document).ready(main);


#2

ok working through step 4 i now have

'''

var add = function(item) {
var html = template(item);
$('.list').append(html);
};
var commands = {
'add *item': add,
};
annyang.addCommands(commands);
annyang.start();
};

};

'''


#3

Looked into privacy setting but dont understand why Im not prompted to allow microphone use.

also does the example page not work?


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.