This is a plugin similar to turbolinks gem of Ruby on Rails that loads only the main content instead to load all page content every time.
Permit to navigate 60% faster in admin panel using Ajax Requests for links and forms.
Support newer browsers with history state.
You can test all features of this plugin in Camaleon CMS Demo.
How to use in my code?
You can add the class name "cama_ajax_request" to your forms or your links to load by this Loader. Also you can add attributes:
Sample:
<form class='cama_ajax_request' data-error-callback="my_function_name"></form>
Note: If you add this classname into container (div, p, ...), this will add the action for all links within this container.
Also, you can bind actions in document to listen request states:
Sample:
$(document).bind("page:before-reload", function(state){
console.log(state);
})