From 43ff34a99bde5a68b33ff9f553baf022acab2826 Mon Sep 17 00:00:00 2001 From: Moataz Nabil Date: Tue, 3 Dec 2024 21:02:01 +0100 Subject: [PATCH] add github actions --- .github/workflows/deploy.yml | 2 -- src/App.tsx | 2 +- vite.config.ts | 2 +- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index ee9d351..fe4d36f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -29,8 +29,6 @@ jobs: - name: Build run: npm run build - env: - PUBLIC_URL: 'https://moatazeldebsy.github.io' - name: Upload artifact uses: actions/upload-pages-artifact@v3 diff --git a/src/App.tsx b/src/App.tsx index 595664d..bb7f71c 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,5 +1,5 @@ import React from 'react'; -import { BrowserRouter as Router, Routes, Route } from 'react-router-dom'; +import { HashRouter as Router, Routes, Route } from 'react-router-dom'; import { Navbar } from './components/layout/Navbar'; import { Navigation } from './components/layout/Navigation'; import { Banner } from './components/layout/Banner'; diff --git a/vite.config.ts b/vite.config.ts index e948ef1..cced6be 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -4,7 +4,7 @@ import react from '@vitejs/plugin-react'; // https://vitejs.dev/config/ export default defineConfig({ plugins: [react()], - base: '/', // Remove repository name from base URL + base: '/test-shop/', // Add repository name back to base URL optimizeDeps: { exclude: ['lucide-react'], },