jbox-web / ajax-datatables-rails

A wrapper around DataTable's ajax methods that allow synchronization with server-side pagination in a Rails app
MIT License
586 stars 228 forks source link

Wiki Guide is outdated #241

Closed NuclearMachine closed 7 years ago

NuclearMachine commented 7 years ago

The wiki is outdated. I tried doing

respond_to do |format|
      format.html
      format.json { render json: PaymentDatatable.new(view_context) }
    end

but to no avail because it only goes to format.html

and yes I have <table id="users-table", data-source="<%= users_path(format: :json) %>" > and the js file in my application.js