You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find in vue-route , it create query by using Object.create(null) and this is a completely blank object that doesn't inherit anything from Object. not any properties or methods from Object. So it dosn't have hasOwnProperty method.
while i see in vue-resource, the 'each' function use obj.hasOwnProperty to transform the query params.
so there is a conflect when i use $route.query as a param in vue-resource $http.get, that's definitely an usual use in vue-router to get an url param object by $route.query.
maybe it can repalced by others like:
{}orObject.create(Object.prototype)
The text was updated successfully, but these errors were encountered:
I use $route.query in vue-resource like this:
and receive an error:
obj.hasOwnProperty is not a function
I find in vue-route , it create query by using Object.create(null) and this is a completely blank object that doesn't inherit anything from Object. not any properties or methods from Object. So it dosn't have hasOwnProperty method.
while i see in vue-resource, the 'each' function use obj.hasOwnProperty to transform the query params.
so there is a conflect when i use $route.query as a param in vue-resource $http.get, that's definitely an usual use in vue-router to get an url param object by $route.query.
maybe it can repalced by others like:
The text was updated successfully, but these errors were encountered: