Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Add compatibility #section- ID after all headers #642

Merged
merged 5 commits into from
Apr 27, 2020

Conversation

domharrington
Copy link
Member

@domharrington domharrington commented Apr 27, 2020

🧰 What's being changed?

Fixes #622

Added a div with a section- prefix after all headings. Is this the correct place for them? Is <div> the right element?

🧪 Testing

See added unit tests

🗳 Checklist

💡 If answering yes to any of the following, include additional info, before/after links, screenshots, etc. where appropriate!

  • 🆕 I'm adding something new!
  • 🐛 I'm fixing a bug!
  • 📸 I've made some changes to the UI!

Sorry, something went wrong.

@domharrington domharrington changed the title Bug/section anchor compatibility Add compatibility #section- ID after all headers Apr 27, 2020
@domharrington domharrington changed the base branch from master to rdmd/next April 27, 2020 21:40
@@ -144,7 +148,8 @@ export function processor(opts = {}) {
.use(!opts.correctnewlines ? remarkBreaks : () => {})
.use(gemojiParser.sanitize(sanitize))
.use(remarkSlug)
.use(remarkRehype, { allowDangerousHTML: true })
.use(sectionAnchorId)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is great.

@rafegoldberg
Copy link
Contributor

@domharrington merging this in!

@rafegoldberg rafegoldberg merged commit e554d65 into rdmd/next Apr 27, 2020
@rafegoldberg rafegoldberg deleted the bug/section-anchor-compatibility branch April 27, 2020 23:02
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prefix RDMD generated anchors.
2 participants