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

Fix ordered list starting number #34

Merged
merged 2 commits into from
Dec 8, 2024

Conversation

Harry-Dang
Copy link
Contributor

If the user starts an ordered list with a value other than 1., it does not get properly rendered.

This PR utilizes the token.start property from Marked and adds it to the ol element's start attribute so that ordered list is rendered with the correct number. In addition, the existing ordered list test was updated and an additional test was added to cover this specific case.

tests/markdown.spec.ts Outdated Show resolved Hide resolved
@sibiraj-s sibiraj-s merged commit d77bd6d into sibiraj-s:master Dec 8, 2024
1 check passed
@sibiraj-s
Copy link
Owner

Thanks @Harry-Dang . This is now available in v3.0.0

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

Successfully merging this pull request may close these issues.

2 participants