I use only jQuery to write JavaScript code. One thing that bothers me is two approaches to writing functions,
First approach
vote = function (action,feedbackId,responseDiv) { alert('hi'); return feedbackId; }
Second approach
function vote(action, feedbackId,responseDiv) { alert('hi'); return feedbackId; }
What is the difference between the two and why should you use the first approach or the second approach?
javascript function
Gaurav sharma
source share