Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extract heading IDs using getHeadingList() from Marked #3171

Closed
colinrotherham opened this issue Sep 25, 2023 · 2 comments
Closed

Extract heading IDs using getHeadingList() from Marked #3171

colinrotherham opened this issue Sep 25, 2023 · 2 comments
Assignees
Labels

Comments

@colinrotherham
Copy link
Contributor

Context

Our Markdown heading ID plugin marked-gfm-heading-id has been updated with a new new export getHeadingList() which means we could remove extractPageHeadings() in future

Raising this issue so we don't lose track of it

Additional information (if applicable)

@domoscargin
Copy link
Contributor

domoscargin commented Apr 18, 2024

I had a look at this from the perspective of getting rid of the extractPageHeadings plugin.

getHeadingList is only useful/available within the marked call, so there's some scoping issues getting it to work within the metalsmith-markdown call in the metalsmith build (and thus avoid the need to loop the files again).

By the time I had it starting to work, I was pretty deep in the weeds with closures and the like, and had generated a lot of extra code, which made it seem like either a bigger piece of work (I didn't get near testing everything), or something I'd need to start over on.

I then got distracted by cycle work and forgot this task existed, so I'll unassign myself for now. Maybe fresh eyes will spot a simpler way to get it working.

@domoscargin domoscargin removed their assignment Apr 18, 2024
@domoscargin domoscargin moved this from In progress 📝 to Backlog 🏃🏼‍♀️ in GOV.UK Design System cycle board Apr 18, 2024
@patrickpatrickpatrick patrickpatrickpatrick self-assigned this May 9, 2024
@patrickpatrickpatrick patrickpatrickpatrick moved this from Backlog 🏃🏼‍♀️ to In progress 📝 in GOV.UK Design System cycle board May 9, 2024
@patrickpatrickpatrick patrickpatrickpatrick moved this from In progress 📝 to Needs review 🔍 in GOV.UK Design System cycle board May 14, 2024
@patrickpatrickpatrick patrickpatrickpatrick moved this from Needs review 🔍 to Done 🏁 in GOV.UK Design System cycle board May 16, 2024
@patrickpatrickpatrick
Copy link
Contributor

Closed by #3793.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

No branches or pull requests

3 participants