mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-04-23 19:01:15 -03:00
Merge pull request #4581 from mqudsi/help_section_workaround
Work around OS X issue with dropped #fragment in launched URLs
This commit is contained in:
@@ -1,2 +1,12 @@
|
||||
</body>
|
||||
<script type='text/javascript'>
|
||||
// Some platforms don't handle launching a browser to navigate a page with
|
||||
// a #fragment specified, so we use this workaround combined with a query string.
|
||||
// See https://github.com/fish-shell/fish-shell/issues/4480
|
||||
var params = new URLSearchParams(window.location.search); //?section=foo
|
||||
var section = params.get("section");
|
||||
if (section != null && location.hash == "") {
|
||||
location.hash = "#" + section;
|
||||
}
|
||||
</script>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user