@lambo-design/shared 1.0.0-beta.13 → 1.0.0-beta.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lambo-design/shared",
3
- "version": "1.0.0-beta.13",
3
+ "version": "1.0.0-beta.14",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "author": "lambo",
@@ -12,12 +12,12 @@ export const hasRoute = ($router, name) => {
12
12
  /**
13
13
  * 判断是否存在路由并且页面存在
14
14
  * @param $router
15
- * @param name
15
+ * @param path
16
16
  * @returns {*|boolean}
17
17
  */
18
- export const hasRouteAndComponent = ($router, name) => {
18
+ export const hasRoutePath = ($router, path) => {
19
19
  let routes = $router.getRoutes();
20
- let res = routes.filter(item => item.name === name && item.component)
20
+ let res = routes.filter(item => item.path === path)
21
21
  return res && res.length > 0
22
22
  }
23
23
  /**