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: don't throw when Shiki doesn't recognize a language #3911

Merged
merged 2 commits into from
Jul 13, 2022

Conversation

JuanM04
Copy link
Contributor

@JuanM04 JuanM04 commented Jul 13, 2022

Fixes #3881

Changes

When a language that isn't registered by Shiki is used, show a warning instead of an error.

Testing

Added tests with a unknown language (it would be nice to analyze the logs, but I don't know how)

Docs

@changeset-bot
Copy link

changeset-bot bot commented Jul 13, 2022

🦋 Changeset detected

Latest commit: 18ebc3d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@astrojs/markdown-remark Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added pkg: astro Related to the core `astro` package (scope) feat: markdown Related to Markdown (scope) labels Jul 13, 2022
@JuanM04 JuanM04 changed the title fix: don't throw when Shiki doesn't recognise a language fix: don't throw when Shiki doesn't recognize a language Jul 13, 2022
@matthewp
Copy link
Contributor

Code looks good. Needs a changeset.

@tony-sull tony-sull merged commit ca45c0c into main Jul 13, 2022
@tony-sull tony-sull deleted the fix/3881-shiki-missing-language branch July 13, 2022 19:32
@astrobot-houston astrobot-houston mentioned this pull request Jul 13, 2022
SiriousHunter pushed a commit to SiriousHunter/astro that referenced this pull request Feb 3, 2023
)

* Don't throw when Shiki doesn't recognise a language

* Changeset
@donmckenna
Copy link

I know this issue is long closed, but I'm still getting an error instead of a warning from Shiki with astro: 3.6.4
Am I missing something?

Screen Shot 2023-12-02 at 9 24 43 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat: markdown Related to Markdown (scope) pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐛 BUG: Shiki missing language registration should not fail markdown processing
5 participants