@lingxiteam/assets 1.0.9-alpha.2 → 1.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/utils/url.js +3 -7
- package/package.json +1 -1
package/es/utils/url.js
CHANGED
|
@@ -51,13 +51,11 @@ export var parseUrlExpression = function parseUrlExpression(urlStr) {
|
|
|
51
51
|
var urlParamsContext = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
52
52
|
var _ref = window.location || {},
|
|
53
53
|
protocol = _ref.protocol,
|
|
54
|
-
|
|
55
|
-
href = _ref$href === void 0 ? '' : _ref$href,
|
|
54
|
+
href = _ref.href,
|
|
56
55
|
port = _ref.port,
|
|
57
56
|
pathname = _ref.pathname,
|
|
58
57
|
host = _ref.host,
|
|
59
|
-
hostname = _ref.hostname
|
|
60
|
-
hash = _ref.hash;
|
|
58
|
+
hostname = _ref.hostname;
|
|
61
59
|
var defaultParams = {
|
|
62
60
|
protocol: protocol,
|
|
63
61
|
href: href,
|
|
@@ -65,9 +63,7 @@ export var parseUrlExpression = function parseUrlExpression(urlStr) {
|
|
|
65
63
|
pathname: pathname,
|
|
66
64
|
host: host,
|
|
67
65
|
hostname: hostname,
|
|
68
|
-
|
|
69
|
-
search: decodeURIComponent(href.split('?').pop() || ''),
|
|
70
|
-
hash: decodeURIComponent(hash)
|
|
66
|
+
search: getSearchObj(href)
|
|
71
67
|
};
|
|
72
68
|
var evalVariableExpression = function evalVariableExpression(text) {
|
|
73
69
|
var params = _objectSpread(_objectSpread({}, defaultParams), urlParamsContext);
|