@edgedev/create-edge-app 1.1.6 → 1.1.8

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/.eslintrc CHANGED
@@ -5,6 +5,7 @@
5
5
  "vue/no-deprecated-slot-attribute": "off",
6
6
  "curly": "off",
7
7
  "no-console": "off",
8
- "antfu/top-level-function": "off"
8
+ "antfu/top-level-function": "off",
9
+ "style/eol-last": "off"
9
10
  }
10
11
  }
@@ -8,14 +8,19 @@ export default defineNuxtRouteMiddleware(async () => {
8
8
  preLoginRoute.value = `${pathname}${search}`
9
9
  }
10
10
 
11
+ const firstSection = window.location.pathname.split('/')[1] || ''
12
+ const loginPath = `/${firstSection}/login`
13
+ console.log('loginPath', loginPath)
14
+
11
15
  const auth: any = useState('auth')
16
+
12
17
  if (auth.value) {
13
18
  if (!auth.value.loggedIn) {
14
- return '/app/login'
19
+ return loginPath
15
20
  }
16
21
  }
17
22
  else {
18
- return '/app/login'
23
+ return loginPath
19
24
  }
20
25
  // EDGE END
21
26
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edgedev/create-edge-app",
3
- "version": "1.1.6",
3
+ "version": "1.1.8",
4
4
  "description": "Create Edge Starter App",
5
5
  "bin": {
6
6
  "create-edge-app": "./bin/cli.js"