Skip to content

Commit b76e6a0

Browse files
fix: resolve deployment path issues for manifest and assets on GitHub Pages
Updated asset and manifest paths from absolute (`/`) to relative (`./`) to ensure compatibility with GitHub Pages hosting Fixed favicon and web manifest links so icons render correctly in production Corrected fetch path in ManifestDataLoader.js to properly load manifest.json Resolved issue where app version displayed as `null` due to manifest load failure
1 parent b87fc1a commit b76e6a0

File tree

7 files changed

+40
-40
lines changed

7 files changed

+40
-40
lines changed

404.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@
1616
<!-- necessary meta tags -->
1717

1818
<!-- app icons -->
19-
<link rel="icon" type="image/png" href="/assets/icons/favicon-32x32.png" sizes="32x32" />
20-
<link rel="icon" type="image/png" href="/assets/icons/favicon-16x16.png" sizes="16x16" />
21-
<link rel="icon" type="image/svg+xml" href="/assets/icons/favicon.svg" />
22-
<link rel="shortcut icon" href="/assets/icons/favicon.ico" />
23-
<link rel="apple-touch-icon" sizes="180x180" href="/assets/icons/apple-touch-icon.png" />
19+
<link rel="icon" type="image/png" href="./assets/icons/favicon-32x32.png" sizes="32x32" />
20+
<link rel="icon" type="image/png" href="./assets/icons/favicon-16x16.png" sizes="16x16" />
21+
<link rel="icon" type="image/svg+xml" href="./assets/icons/favicon.svg" />
22+
<link rel="shortcut icon" href="./assets/icons/favicon.ico" />
23+
<link rel="apple-touch-icon" sizes="180x180" href="./assets/icons/apple-touch-icon.png" />
2424

2525
<meta name="apple-mobile-web-app-title" content="GitHub Connection Visualizer" />
2626

27-
<link rel="manifest" href="/assets/icons/site.webmanifest" />
28-
<link rel="mask-icon" href="/assets/icons/favicon.svg" color="#fdfffc">
27+
<link rel="manifest" href="./assets/icons/site.webmanifest" />
28+
<link rel="mask-icon" href="./assets/icons/favicon.svg" color="#fdfffc">
2929
<!-- app icons -->
3030

3131
<!-- open graph and facebook preview -->
@@ -125,7 +125,7 @@
125125
<span class="text-color text-capitalize">he page you&rsquo;re looking for doesn&rsquo;t exist or may have been moved.</span>
126126
</div>
127127
<div class="col-12 pt-3">
128-
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="/" role="button" aria-disabled="true">
128+
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="./" role="button" aria-disabled="true">
129129
<i class="bi bi-house-door-fill text-color"></i>&nbsp;
130130
Back To Home
131131
</a>

assets/icons/site.webmanifest

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,23 +3,23 @@
33
"short_name": "GHCV",
44
"icons": [
55
{
6-
"src": "/assets/icons/android-chrome-192x192.png",
6+
"src": "./assets/icons/android-chrome-192x192.png",
77
"sizes": "192x192",
88
"type": "image/png"
99
},
1010
{
11-
"src": "/assets/icons/android-chrome-512x512.png",
11+
"src": "./assets/icons/android-chrome-512x512.png",
1212
"sizes": "512x512",
1313
"type": "image/png"
1414
},
1515
{
16-
"src": "/assets/icons/favicon-16x16.png",
16+
"src": "./assets/icons/favicon-16x16.png",
1717
"sizes": "16x16",
1818
"type": "image/png",
1919
"purpose": "maskable"
2020
},
2121
{
22-
"src": "/assets/icons/favicon-32x32.png",
22+
"src": "./assets/icons/favicon-32x32.png",
2323
"sizes": "32x32",
2424
"type": "image/png",
2525
"purpose": "maskable"

index.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@
1616
<!-- necessary meta tags -->
1717

1818
<!-- app icons -->
19-
<link rel="icon" type="image/png" href="/assets/icons/favicon-32x32.png" sizes="32x32" />
20-
<link rel="icon" type="image/png" href="/assets/icons/favicon-16x16.png" sizes="16x16" />
21-
<link rel="icon" type="image/svg+xml" href="/assets/icons/favicon.svg" />
22-
<link rel="shortcut icon" href="/assets/icons/favicon.ico" />
23-
<link rel="apple-touch-icon" sizes="180x180" href="/assets/icons/apple-touch-icon.png" />
19+
<link rel="icon" type="image/png" href="./assets/icons/favicon-32x32.png" sizes="32x32" />
20+
<link rel="icon" type="image/png" href="./assets/icons/favicon-16x16.png" sizes="16x16" />
21+
<link rel="icon" type="image/svg+xml" href="./assets/icons/favicon.svg" />
22+
<link rel="shortcut icon" href="./assets/icons/favicon.ico" />
23+
<link rel="apple-touch-icon" sizes="180x180" href="./assets/icons/apple-touch-icon.png" />
2424

2525
<meta name="apple-mobile-web-app-title" content="GitHub Connection Visualizer" />
2626

27-
<link rel="manifest" href="/assets/icons/site.webmanifest" />
28-
<link rel="mask-icon" href="/assets/icons/favicon.svg" color="#fdfffc">
27+
<link rel="manifest" href="./assets/icons/site.webmanifest" />
28+
<link rel="mask-icon" href="./assets/icons/favicon.svg" color="#fdfffc">
2929
<!-- app icons -->
3030

3131
<!-- open graph and facebook preview -->
@@ -875,7 +875,7 @@
875875
by GitHub. All content posted here is public and owned by its respective authors.</span>
876876
<div class="col-12 py-3">
877877
<div class="d-flex flex-row justify-content-center align-items-center column-gap-3">
878-
<a href="/" class="header-color footer-link-button">Home</a>
878+
<a href="./" class="header-color footer-link-button">Home</a>
879879
<span class="muted-text-color">|</span>
880880
<a href="./privacy-policy.html" class="header-color footer-link-button">Privacy Policy</a>
881881
<span class="muted-text-color">|</span>

js/util/ManifestDataLoader.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export class ManifestDataLoader{
2525
if(!this.#manifestData){
2626
// ManifestData object not available
2727
try {
28-
const response = await fetch("/manifest.json");
28+
const response = await fetch("./manifest.json");
2929

3030
// check if the fetching process is completed or not
3131
if (response.ok) {

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "GitHub Connection Visualizer",
33
"short_name": "GHCV",
44
"description": "Discover And Manage Your GitHub Connections With Ease.",
5-
"start_url": "/",
5+
"start_url": "./",
66
"version": "1.0.0",
77
"display": "standalone",
88
"background_color": "#131315",

privacy-policy.html

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@
1616
<!-- necessary meta tags -->
1717

1818
<!-- app icons -->
19-
<link rel="icon" type="image/png" href="/assets/icons/favicon-32x32.png" sizes="32x32" />
20-
<link rel="icon" type="image/png" href="/assets/icons/favicon-16x16.png" sizes="16x16" />
21-
<link rel="icon" type="image/svg+xml" href="/assets/icons/favicon.svg" />
22-
<link rel="shortcut icon" href="/assets/icons/favicon.ico" />
23-
<link rel="apple-touch-icon" sizes="180x180" href="/assets/icons/apple-touch-icon.png" />
19+
<link rel="icon" type="image/png" href="./assets/icons/favicon-32x32.png" sizes="32x32" />
20+
<link rel="icon" type="image/png" href="./assets/icons/favicon-16x16.png" sizes="16x16" />
21+
<link rel="icon" type="image/svg+xml" href="./assets/icons/favicon.svg" />
22+
<link rel="shortcut icon" href="./assets/icons/favicon.ico" />
23+
<link rel="apple-touch-icon" sizes="180x180" href="./assets/icons/apple-touch-icon.png" />
2424

2525
<meta name="apple-mobile-web-app-title" content="GitHub Connection Visualizer" />
2626

27-
<link rel="manifest" href="/assets/icons/site.webmanifest" />
28-
<link rel="mask-icon" href="/assets/icons/favicon.svg" color="#fdfffc">
27+
<link rel="manifest" href="./assets/icons/site.webmanifest" />
28+
<link rel="mask-icon" href="./assets/icons/favicon.svg" color="#fdfffc">
2929
<!-- app icons -->
3030

3131
<!-- open graph and facebook preview -->
@@ -119,7 +119,7 @@
119119
<div class="col-12 col-sm-12 col-md-12 col-lg-10 col-xl-9 card card-wrapper glass-card px-4 py-3">
120120
<div class="card-body">
121121
<div class="p-4 fab-wrapper-top-left">
122-
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="/" role="button" aria-disabled="true">
122+
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="./" role="button" aria-disabled="true">
123123
<i class="bi bi-house-door-fill text-color"></i>&nbsp;
124124
Back To Home
125125
</a>
@@ -191,7 +191,7 @@
191191
by GitHub. All content posted here is public and owned by its respective authors.</span>
192192
<div class="col-12 py-3">
193193
<div class="d-flex flex-row justify-content-center align-items-center column-gap-3">
194-
<a href="/" class="header-color footer-link-button">Home</a>
194+
<a href="./" class="header-color footer-link-button">Home</a>
195195
<span class="muted-text-color">|</span>
196196
<a href="./privacy-policy.html" class="header-color footer-link-button">Privacy Policy</a>
197197
<span class="muted-text-color">|</span>

terms-of-use.html

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@
1616
<!-- necessary meta tags -->
1717

1818
<!-- app icons -->
19-
<link rel="icon" type="image/png" href="/assets/icons/favicon-32x32.png" sizes="32x32" />
20-
<link rel="icon" type="image/png" href="/assets/icons/favicon-16x16.png" sizes="16x16" />
21-
<link rel="icon" type="image/svg+xml" href="/assets/icons/favicon.svg" />
22-
<link rel="shortcut icon" href="/assets/icons/favicon.ico" />
23-
<link rel="apple-touch-icon" sizes="180x180" href="/assets/icons/apple-touch-icon.png" />
19+
<link rel="icon" type="image/png" href="./assets/icons/favicon-32x32.png" sizes="32x32" />
20+
<link rel="icon" type="image/png" href="./assets/icons/favicon-16x16.png" sizes="16x16" />
21+
<link rel="icon" type="image/svg+xml" href="./assets/icons/favicon.svg" />
22+
<link rel="shortcut icon" href="./assets/icons/favicon.ico" />
23+
<link rel="apple-touch-icon" sizes="180x180" href="./assets/icons/apple-touch-icon.png" />
2424

2525
<meta name="apple-mobile-web-app-title" content="GitHub Connection Visualizer" />
2626

27-
<link rel="manifest" href="/assets/icons/site.webmanifest" />
28-
<link rel="mask-icon" href="/assets/icons/favicon.svg" color="#fdfffc">
27+
<link rel="manifest" href="./assets/icons/site.webmanifest" />
28+
<link rel="mask-icon" href="./assets/icons/favicon.svg" color="#fdfffc">
2929
<!-- app icons -->
3030

3131
<!-- open graph and facebook preview -->
@@ -119,7 +119,7 @@
119119
<div class="col-12 col-sm-12 col-md-12 col-lg-10 col-xl-9 card card-wrapper glass-card px-4 py-3">
120120
<div class="card-body">
121121
<div class="p-4 fab-wrapper-top-left">
122-
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="/" role="button" aria-disabled="true">
122+
<a class="btn btn-outline-secondary pagination-button-wrapper rounded-5 py-2" href="./" role="button" aria-disabled="true">
123123
<i class="bi bi-house-door-fill text-color"></i>&nbsp;
124124
Back To Home
125125
</a>
@@ -230,7 +230,7 @@
230230
by GitHub. All content posted here is public and owned by its respective authors.</span>
231231
<div class="col-12 py-3">
232232
<div class="d-flex flex-row justify-content-center align-items-center column-gap-3">
233-
<a href="/" class="header-color footer-link-button">Home</a>
233+
<a href="./" class="header-color footer-link-button">Home</a>
234234
<span class="muted-text-color">|</span>
235235
<a href="./privacy-policy.html" class="header-color footer-link-button">Privacy Policy</a>
236236
<span class="muted-text-color">|</span>

0 commit comments

Comments
 (0)