Skip to content

Commit

Permalink
added comment in 404 page
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitmalhotra1420 committed May 20, 2024
1 parent 3d94b4c commit 7be3b00
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions public/404.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@
// https://username.github.io/repo-name/?/one/two&a=b~and~c=d#qwe
// Otherwise, leave pathSegmentsToKeep as 0.

// Note:
// This file needs to be present in the root of gh-pages branch along side pr-preview folder.
// As the preview url has 3 levels of nesting push-dapp/pr-preview/pr-{prNumber}.
// So the 404.html file present in the public folder won't work so we need to put this extra 404.html in gh-pages branch root.

var isPrPreview = window.location.pathname.includes('/pr-preview/');
var pathSegmentsToKeep = isPrPreview ? 3 : 0;

Expand Down

0 comments on commit 7be3b00

Please sign in to comment.