question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

"uslugify" breaks header anchors list

See original GitHub issue

Description

Setting custom slugify function “uslugify” from pymodown breaks header anchors block at the right.

markdown_extensions:
    ...
    - toc:
          permalink: '#'
          slugify: !!python/name:pymdownx.slugs.uslugify
    ...

Expected behavior

When scrolling down headers are fading out. This gives a visual understanding of current position on the page.

Actual behavior

When scrolling, the browser console spams the following error: error

error2

Steps to reproduce the bug

  1. In mkdocs.yml set a custom slugify function (“uslugify” in my case)
  2. Add some cyrillic headers in index.md
  3. Anchor links are not fading and the console spams the error when scrolling the page

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
squidfunkcommented, Jan 28, 2019

Perfect! I will issue a release within the next few days. Until then, please use the current master.

0reactions
squidfunkcommented, Jan 29, 2019

Fix released as part of 3.3.0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

markdown-it-anchor - npm
A markdown-it plugin that adds an id attribute to headings and ... that gets the plain text from a list of markdown-it inline...
Read more >
offsetting an html anchor to adjust for fixed header [duplicate]
I was looking for a solution to this as well. In my case, it was pretty easy. I have a list menu with...
Read more >
What workaround is recommended to fix broken anchors?
The first, easiest option would be to use the Table of Contents macro. This macro will automatically create a list of links to...
Read more >
Create Anchor Links in Help Scout Docs
Anchor links allow readers to jump to a specific part of the page. ... We added an id attribute to the h3 header...
Read more >
T4280 Embed anchor in remark up text and later link to it.
If I change the header title, all of my links to that break immediately. Long header names are truncated in a not obvious...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found