Title: Hash fragment should not be modified by Angular running PathLocationStrategy · Issue #8105 · angular/angular · GitHub
Open Graph Title: Hash fragment should not be modified by Angular running PathLocationStrategy · Issue #8105 · angular/angular
X Title: Hash fragment should not be modified by Angular running PathLocationStrategy · Issue #8105 · angular/angular
Description: When the location strategy is PathLocationStrategy the hash fragment is still cleared upon navigation. This happens in the RootRouter.commit method, which itself calls Location.go .. and ends calling History.pushState. I think it's reaso...
Open Graph Description: When the location strategy is PathLocationStrategy the hash fragment is still cleared upon navigation. This happens in the RootRouter.commit method, which itself calls Location.go .. and ends calli...
X Description: When the location strategy is PathLocationStrategy the hash fragment is still cleared upon navigation. This happens in the RootRouter.commit method, which itself calls Location.go .. and ends calli...
Opengraph URL: https://github.com/angular/angular/issues/8105
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Hash fragment should not be modified by Angular running PathLocationStrategy ","articleBody":"When the location strategy is `PathLocationStrategy` the hash fragment is still cleared upon navigation.\n\nThis happens in the [RootRouter.commit](https://github.com/angular/angular/blob/60727c4d2ba1e4b0b9455c767d0ef152bcedc7c2/modules/angular2/src/router/router.ts#L517) method, which itself calls `Location.go` .. and ends calling `History.pushState`.\n\nI think it's reasonable (or, actually, expected) NOT to tangle with the hash fragment at all, when the strategy is using URL paths.. what do you think?\n\nA very short piece of code added to `RootRouter.commit` could help achieving this:\n\n```\nvar hash = this._location.hash;\nif (this._location.platformStrategy instanceof PathLocationStrategy && hash.length > 0) {\n emitPath += '#' + hash;\n}\n```\n\nWhat do you think? Without this change it's hard to embed apps using different location strategies.\n","author":{"url":"https://github.com/emesx","@type":"Person","name":"emesx"},"datePublished":"2016-04-16T14:49:31Z","url":"https://github.com/angular/angular/issues/8105"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:162f1742-6a74-f3b6-9fe3-4e7aabc548a8 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E274:3CBB3E:12CD25F:17D88E0:6B0161F5 |
| html-safe-nonce | 71e60567d9624ded5fbd04338df0b2650b54de33cd66ea9bf8aff29b3649df7c |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMjc0OjNDQkIzRToxMkNEMjVGOjE3RDg4RTA6NkIwMTYxRjUiLCJ2aXNpdG9yX2lkIjoiNjQzNjc1NDAyODE1OTM5NDI5MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | c451cac5513145fabec547c7ad2c69c83f63747b44312d43e40ed0a38e7fbaad |
| hovercard-subject-tag | issue:148859623 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angular/8105/issue_layout |
| twitter:image | https://opengraph.githubassets.com/2e372f7bc774a6d8921d97124aa4de6122d4fd1267622f052b10c26761b68a49/angular/angular/issues/8105 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/2e372f7bc774a6d8921d97124aa4de6122d4fd1267622f052b10c26761b68a49/angular/angular/issues/8105 |
| og:image:alt | When the location strategy is PathLocationStrategy the hash fragment is still cleared upon navigation. This happens in the RootRouter.commit method, which itself calls Location.go .. and ends calli... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | emesx |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/angular/angular git https://github.com/angular/angular.git |
| octolytics-dimension-user_id | 139426 |
| octolytics-dimension-user_login | angular |
| octolytics-dimension-repository_id | 24195339 |
| octolytics-dimension-repository_nwo | angular/angular |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 24195339 |
| octolytics-dimension-repository_network_root_nwo | angular/angular |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width