Repository navigation
Conversation
|
You can preview 52f3a71 at https://pr25999-52f3a71.ngbuilds.io/. |
petebacondarwin
left a comment
There was a problem hiding this comment.
I guess there are actually no cases where we expect there to be a .html extension on a URL in practice?
Do we care about .htm?
LGTM
Not afaict 😁
Not afaict. Actually, I inteded to add an e2e test, but forgot it. I'll add it later. |
|
Blocked on #25997 (for patch branch). |
Firebase used to do it automatically (with `cleanUrls: true`), but it stopped doing it unless the resulting URL corresponds to an existing file (which is not always the case in angular.io; e.g. the resulting URL might be matched by a new redirect rule). This change in Firebase hosting behavior resulted in some URLs not being correctly redirected (e.g. URLs to the archived v2 site, or `.html` suffixed URLs from 3rd-party sites). This commit fixes it, by configuring Firebase hosting to strip off the `.html` extension and redirect (if no other redirect rule matched).
52f3a71 to
764717a
Compare
|
You can preview 764717a at https://pr25999-764717a.ngbuilds.io/. |
|
Rebased on master and added an e2e test. This should be good to go once #25997 is merged. |
| page.sitemapUrls.forEach((url, i) => { | ||
| it(`should not redirect '${url}' (${i + 1}/${page.sitemapUrls.length})`, async () => { | ||
| await page.goTo(url); | ||
| page.sitemapUrls.forEach((path, i) => { |
There was a problem hiding this comment.
For clarity 😇
These are paths and it didn't read correctly to have baseUrl + url --> someUrl.
path is a more accurate name for what this variable holds 😃
angular#25999) Firebase used to do it automatically (with `cleanUrls: true`), but it stopped doing it unless the resulting URL corresponds to an existing file (which is not always the case in angular.io; e.g. the resulting URL might be matched by a new redirect rule). This change in Firebase hosting behavior resulted in some URLs not being correctly redirected (e.g. URLs to the archived v2 site, or `.html` suffixed URLs from 3rd-party sites). This commit fixes it, by configuring Firebase hosting to strip off the `.html` extension and redirect (if no other redirect rule matched). PR Close angular#25999
#25999) (#25997) Firebase used to do it automatically (with `cleanUrls: true`), but it stopped doing it unless the resulting URL corresponds to an existing file (which is not always the case in angular.io; e.g. the resulting URL might be matched by a new redirect rule). This change in Firebase hosting behavior resulted in some URLs not being correctly redirected (e.g. URLs to the archived v2 site, or `.html` suffixed URLs from 3rd-party sites). This commit fixes it, by configuring Firebase hosting to strip off the `.html` extension and redirect (if no other redirect rule matched). PR Close #25999 PR Close #25997
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Firebase used to do it automatically (with
cleanUrls: true), but it stopped doing it unless the resulting URL corresponds to an existing file (which is not always the case in angular.io; e.g. the resulting URL might be matched by a new redirect rule).This change in Firebase hosting behavior resulted in some URLs not being correctly redirected (e.g. URLs to the archived v2 site, or
.htmlsuffixed URLs from 3rd-party sites).This commit fixes it, by configuring Firebase hosting to strip off the
.htmlextension and redirect (if no other redirect rule matched).