H5修改当前URL地址重新加载新的地址
根据项目需求自行修改,我当前实现的是去掉URL携带参数
let hash=window.location.hash;
let protocol = window.location.protocol;
let host = window.location.hostname;
let pathname = window.location.pathname;
location.replace(protocol+'//'+host+pathname+hash);
此篇文章只供自己参考 我只是代码的搬运工