Files
shiny/srcjs/_start.js
Barbara Borges Ribeiro a0b917a207 support pushState for pseudo-nav
see the documentation for details (`?updateQueryString` and `?getQueryString`)
2017-01-25 23:45:26 +00:00

16 lines
386 B
JavaScript

(function() {
var $ = jQuery;
var exports = window.Shiny = window.Shiny || {};
var origPushState = window.history.pushState;
window.history.pushState = function() {
var result = origPushState.apply(this, arguments);
$(document).trigger("pushstate");
return result;
};
$(document).on('submit', 'form:not([action])', function(e) {
e.preventDefault();
});