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

Add lang global directive and constructor option #376

Merged
merged 4 commits into from
Oct 15, 2023
Merged

Conversation

yhatt
Copy link
Member

@yhatt yhatt commented Oct 14, 2023

Marpit Markdown document becomes able to assign lang attribute for each slide through lang global directive or constructor option.

---
lang: en-US
---

...

or:

new Marpit({ lang: 'en-US' })

The constructor option is for setting the default lang attribute value, and Markdown author can override lang attribute by the global directive.

Output

<section lang="en-US">
  ...
</section>

Related issues in Marp ecosystem

@yhatt yhatt merged commit 0d274b9 into main Oct 15, 2023
5 checks passed
@yhatt yhatt deleted the lang-directive branch October 15, 2023 11:07
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.

1 participant