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

Commit cc6ca96

Browse files
Merge pull request #4 from foundersandcoders/employer_fetch_names
Employer fetch names
2 parents 1815c14 + eb4322e commit cc6ca96

File tree

3 files changed

+15
-5
lines changed

3 files changed

+15
-5
lines changed

package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@
44
"version": "0.0.0",
55
"type": "module",
66
"scripts": {
7-
"dev": "vite",
8-
"build": "tsc -b && vite build",
7+
"dev": "vite --mode development",
8+
"prod": "vite --mode production",
9+
"build": "tsc -b && vite build --mode production",
910
"lint": "eslint .",
10-
"preview": "vite preview",
11+
"preview": "vite preview --mode production",
1112
"deploy": "npm run build && gh-pages -d dist"
1213
},
1314
"homepage": "https://foundersandcoders.github.io/LIFT-frontend",

src/pages/employers/EmployersDashboard.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,19 @@ import Modal from '../../components/ui/Modal';
44
import statements from '../../data/statements.json';
55
// import { FaLock, FaLockOpen } from 'react-icons/fa';
66
import StatementsTable from '../../components/ui/StatementsTable';
7-
//import ActionsTable from '../../components/ui/ActionsTable';
87
import ActionsManager from '../../components/ui/ActionsManager';
98

109
// Utility function to generate dropdown options. Include 'All' by default.
1110
const getUniqueOptions = (data: string[]) => Array.from(new Set(data));
1211

12+
//Testing Fetch
13+
const API_URL = import.meta.env.VITE_API_URL;
14+
console.log('Backend API:', API_URL);
15+
16+
fetch(`${API_URL}/n/s/Alex`)
17+
.then((response) => response.json())
18+
.then((data) => console.log(data));
19+
1320
const EmployersDashboard: React.FC = () => {
1421
const [filters, setFilters] = useState({
1522
subject: 'All',

vite.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ import react from '@vitejs/plugin-react';
44
// https://vite.dev/config/
55
export default defineConfig({
66
base: './',
7-
// base: '/LIFT-frontend/',
87
plugins: [react()],
8+
server: {
9+
port: 5000,
10+
},
911
});

0 commit comments

Comments
 (0)