Skip to content
This repository was archived by the owner on Mar 21, 2025. It is now read-only.

Commit b59cd88

Browse files
committed
created config files to remove hardcoded values
1 parent bc822df commit b59cd88

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

.env

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
VUE_APP_NETLIFY_URL = https://simple-vue-netlify-auth.netlify.com/

src/helpers/init-auth.js

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
import GoTrue from "gotrue-js";
22

3-
//TODO - detect local host then use parameter from a config or something else
4-
53
export const Auth = new GoTrue({
6-
APIUrl: "https://simple-vue-netlify-auth.netlify.com/.netlify/identity",
4+
APIUrl: process.env.VUE_APP_NETLIFY_URL + ".netlify/identity",
75
audience: "",
86
setCookie: false
9-
});
10-
11-
console.log("hello from go true helper", Auth)
7+
})

src/main.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@ new Vue({
1212
store,
1313
})
1414

15-
// store.commit("auth/SET_GOTRUE", GoTrueAuth)
16-
17-
1815
restoreState()
1916
attemptToAuthoriseTokens()
2017

0 commit comments

Comments
 (0)