Comparing version 0.0.11 to 0.0.12
@@ -43,5 +43,2 @@ 'use strict'; | ||
value: function parseUrl(url) { | ||
if (!url && 'undefined' !== typeof document) { | ||
url = document.URL; | ||
} | ||
var separator = -1 !== url.indexOf('#') ? '#' : '/'; | ||
@@ -65,6 +62,8 @@ var params = url.split(separator); | ||
var state = _pageStore2.default.getState(); | ||
var parseUrl = state.parseUrl ? state.parseUrl : self.parseUrl; | ||
var stateParseUrl = state.get('parseUrl'); | ||
var parseUrl = stateParseUrl ? stateParseUrl : self.parseUrl; | ||
var configs = _extends({ parseUrl: parseUrl }, parseUrl(url)); | ||
self.update(configs); | ||
}; | ||
var curUrl = props.url ? props.url : document.URL; | ||
setTimeout(function () { | ||
@@ -74,6 +73,6 @@ self.setState({ | ||
}); | ||
updateWithUrl(props.url); | ||
updateWithUrl(curUrl); | ||
}); | ||
window.onpopstate = function (e) { | ||
updateWithUrl(props.url); | ||
updateWithUrl(curUrl); | ||
}; | ||
@@ -80,0 +79,0 @@ } |
{ | ||
"name": "reshow", | ||
"version": "0.0.11", | ||
"version": "0.0.12", | ||
"description": "Flux Reducer Present Library", | ||
@@ -5,0 +5,0 @@ "main": "./build/src/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
18294
320