Skip to content

Commit

Permalink
Merge pull request #25 from Alpha-e-Um/feature/#22/baseURL
Browse files Browse the repository at this point in the history
Feature/#22/base url
  • Loading branch information
ji-hunc authored Apr 10, 2024
2 parents c0459d4 + bab96a7 commit 43ad63e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/lib/axios.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import axios from "axios";

export const axiosWithAuth = axios.create({
// baseURL: "http://e-um.site",
baseURL: "http://localhost:8080",
baseURL:
process.env.NODE_ENV === "development"
? "http://localhost:8080"
: "https://e-um.site",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${localStorage.getItem("access_token")}`,
Expand Down

0 comments on commit 43ad63e

Please sign in to comment.