@@ -248,7 +248,7 @@ with or without [WOW.js](https://github.com/matthieua/WOW).
|
|||||||
new Pjax({
|
new Pjax({
|
||||||
selectors: ["title", ".js-Pjax"],
|
selectors: ["title", ".js-Pjax"],
|
||||||
switches: {
|
switches: {
|
||||||
".js-Pjax": require("pjax/lib/switches.js").sideBySide
|
".js-Pjax": Pjax.switches.sideBySide
|
||||||
},
|
},
|
||||||
switchesOptions: {
|
switchesOptions: {
|
||||||
".js-Pjax": {
|
".js-Pjax": {
|
||||||
|
|||||||
4
index.js
4
index.js
@@ -9,6 +9,8 @@ var on = require("./lib/events/on.js")
|
|||||||
// var off = require("./lib/events/on.js")
|
// var off = require("./lib/events/on.js")
|
||||||
var trigger = require("./lib/events/trigger.js")
|
var trigger = require("./lib/events/trigger.js")
|
||||||
|
|
||||||
|
var defaultSwitches = require("./lib/switches")
|
||||||
|
|
||||||
|
|
||||||
var Pjax = function(options) {
|
var Pjax = function(options) {
|
||||||
this.firstrun = true
|
this.firstrun = true
|
||||||
@@ -42,6 +44,8 @@ var Pjax = function(options) {
|
|||||||
}.bind(this))
|
}.bind(this))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Pjax.switches = defaultSwitches
|
||||||
|
|
||||||
Pjax.prototype = {
|
Pjax.prototype = {
|
||||||
log: require("./lib/proto/log.js"),
|
log: require("./lib/proto/log.js"),
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user