【fix ESLint】utils/util

This commit is contained in:
zhaoxiao
2023-03-09 10:13:19 +08:00
parent 496e89aea1
commit 0c0799bfa3
+1 -1
View File
@@ -109,7 +109,7 @@ function generateChildRouters (data) {
} else { } else {
component = 'views/' + item.component component = 'views/' + item.component
} }
const URL = (item.meta.url || '').replace(/{{([^}}]+)?}}/g, (s1, s2) => eval(s2)) // URL支持{{ window.xxx }}占位符变量 const URL = (item.meta.url || '').replace(/{{([^}}]+)?}}/g, (s1, s2) => evil(s2)) // URL支持{{ window.xxx }}占位符变量
if (isURL(URL) || (item.meta.url && item.meta.url.indexOf('{{') === 0)) { if (isURL(URL) || (item.meta.url && item.meta.url.indexOf('{{') === 0)) {
item.meta.url = URL item.meta.url = URL
} }