rekord-jquery
A rekord binding to jquery - implementing Rekord.rest.
The easiest way to install is by using bower via bower install rekord-jquery
.
You can add global options to send to $.ajax by modifying Rekord.jQuery.options
or by overriding the Rekord.jQuery.adjustOptions
function which is given (options, database, method, model, data, url, success, failure)
and should be used to dynamically modify the options.
// Add global optionsRekordjQueryoptionsusername = 'John';RekordjQueryoptionspassword = 'password#1'; // Add/override options dynamicallyRekordjQuery { if databasename === 'todos' && model optionsurl = databaseapi + modellist_id + '/todos/' + model; }; // Override how options are processedRekordjQuery { $; // default}; // The class instantiated with a database instance that implements Rekord.restRekordjQueryRestClass; // The function which returns a Rekord.rest implementation given a database// Normally Rekord.rest is the same value but multiple back-ends could be usedRekordjQueryrest;