1
0
forked from fr/deguapp

Added .env file

This commit is contained in:
Filip Rojek 2024-05-08 21:30:30 +02:00
parent b17cf25970
commit 652a3b56d7
3 changed files with 4 additions and 1 deletions

1
frontend/.env.example Normal file
View File

@ -0,0 +1 @@
EXPO_PUBLIC_API_URL=http://10.69.1.137:6060/api/v1

2
frontend/.gitignore vendored
View File

@ -33,3 +33,5 @@ yarn-error.*
# typescript # typescript
*.tsbuildinfo *.tsbuildinfo
.env

View File

@ -2,7 +2,7 @@ import { createContext, useContext, useEffect, useState } from "react";
import storageUtil from "./storage"; import storageUtil from "./storage";
const TOKEN_KEY = "my-jwt"; const TOKEN_KEY = "my-jwt";
export const API_URL = "http://10.69.1.137:6060/api/v1"; export const API_URL = process.env.EXPO_PUBLIC_API_URL;
const AuthContext = createContext(null); const AuthContext = createContext(null);
export function useAuth() { export function useAuth() {