I receive an error wrong number of arguments (given 1, expected 2..3) how can i apply it in a each loop ? I want to be able to edit it inplace in an each loop
<%= best_in_place s.message %>
application.js
//= require jquery_ujs
//= require jquery.purr
user.coffee
jQuery ->
$('.best_in_place').best_in_place()
version best_in_place 3.1.1
OR
Is there a more better way of implementing an inplace editing
See the arguments the best_in_place method expects to receive. You're passing only one.
objectmeans an object or specific record.fieldis the attribute which to edit - in your case it could bemessage.optionsall the options it accepts.Most probably you need something like: