Skip to content

Commit

Permalink
ignore links to '#' (#1756)
Browse files Browse the repository at this point in the history
  • Loading branch information
mwcz authored and Keats committed Feb 14, 2022
1 parent 821fa38 commit a13279e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions components/rendering/src/markdown.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ fn fix_link(
if is_external_link(link) {
external_links.push(link.to_owned());
link.to_owned()
} else if link == "#" {
link.to_string()
} else if link.starts_with("#") {
// local anchor without the internal zola path
if let Some(current_path) = context.current_page_path {
Expand Down

0 comments on commit a13279e

Please sign in to comment.