Closed
Description
Version
3.0.3
Reproduction link
Sorry, It is hard to supply a minimal reproduction
Steps to reproduce
Visit http://a.b.c/#/test?d=%25
Vue-router will throw a warning URIError: URI malformed
, and abandon all the query params.
What is expected?
DecodeURI once is enough.
What is actually happening?
DecodeURI twice.
ref:
vue-router/src/history/hash.js
Lines 100 to 106 in 627027f
Lines 37 to 63 in 627027f
The getHash
method already decoded href, but parseQuery
decode it again. So caused URIError: URI malformed
.
Maybe decoding in getHash
is not necessary.