aws-amplify / aws-amplify/amplify-hosting

Rewrite and Redirect base path to folder

Open
#1,486 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Dockerfile
Stars
481
Forks
123
PR merge metrics
No merged PRs in 30d

Description

I have a website like

https://example.com

running a React SPA so the /<*> is replaying to index.html which is working great.
I also connected

https://othersite.com

which is also going to /index.html

however I would like to be able to route

https://othersite.com -> https://othersite.com/a/1

However trying to do so then causes a chain of /a/1/a/1/a/1. My goal is that the address bar shows the /a/1 site, but everything is still relayed through /index.html

Contributor guide

Open the contributing guide

Research direction

Start by reviewing AWS Amplify Hosting rewrite and redirect behavior for custom domains and React SPA fallback rules. Reproduce the two-domain setup, then verify that the second domain displays /a/1 in the address bar without repeatedly appending the path while requests are still served through /index.html.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, react
Domain
cloud, web-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.