标题 JS获取地址栏参数 export const getParam = (name) => {//获取url 参数 let reg = new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)') return decodeURIComponent((reg.exec(location.href) || ['',""])[1].replace(/\+/g, '%20')) || null; }