Spaces:
Sleeping
Sleeping
team99tech commited on
Commit ·
de1f2ba
1
Parent(s): 07794dd
added
Browse files- frontend/lib/api.ts +1 -1
- frontend/next.config.mjs +13 -0
frontend/lib/api.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
import { ExtractionResult, AssessmentResult } from "./types"
|
| 2 |
|
| 3 |
-
const BASE = process.env.NEXT_PUBLIC_API_URL ?? "
|
| 4 |
|
| 5 |
export async function uploadFile(
|
| 6 |
endpoint: "jd" | "resume",
|
|
|
|
| 1 |
import { ExtractionResult, AssessmentResult } from "./types"
|
| 2 |
|
| 3 |
+
const BASE = process.env.NEXT_PUBLIC_API_URL ?? "/api"
|
| 4 |
|
| 5 |
export async function uploadFile(
|
| 6 |
endpoint: "jd" | "resume",
|
frontend/next.config.mjs
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
/** @type {import('next').NextConfig} */
|
| 2 |
+
const nextConfig = {
|
| 3 |
+
async rewrites() {
|
| 4 |
+
return [
|
| 5 |
+
{
|
| 6 |
+
source: "/api/:path*",
|
| 7 |
+
destination: "http://127.0.0.1:8000/:path*",
|
| 8 |
+
},
|
| 9 |
+
];
|
| 10 |
+
},
|
| 11 |
+
};
|
| 12 |
+
|
| 13 |
+
export default nextConfig;
|