Skip to content
 
 

Latest commit

 

History

40 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

meteor-x-editable

Smart package for x-editable in place editor

textarea example

template

<p id="textArea" class="editable" data-type="textarea" data-placeholder="Enter text" data-emptytext="Click to enter text" data-rows="4">{{textArea}}</p>

rendered callback

$(template.find('#textArea.editable:not(.editable-click)')).editable('destroy').editable({
  success: function(response, newValue) {
    <do something with newValue - usually a collection.update call>
}});

note the :not(..) selector + the destroy method call prevent multiple instances of editable controls while allowing the control to remain reactive. one could use the {{#constant}}<editable>{{/constant}} wrapper pattern to allow for a single editable initialization

About

Smart package for x-editable in place editor

Resources

Stars

6 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages