Skip to content

Commit

Permalink
add icons for javascript and typescript langs
Browse files Browse the repository at this point in the history
  • Loading branch information
dimaMachina committed Dec 18, 2024
1 parent 18ab9f9 commit 549eb71
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/itchy-frogs-shop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"nextra": patch
---

add icons for ```javascript and ```typescript langs
2 changes: 2 additions & 0 deletions packages/nextra/src/client/hocs/with-icons.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,12 @@ import type { PreProps } from '../mdx-components/pre/index.js'

function getIcon(language: string) {
switch (language) {
case 'javascript':
case 'js':
case 'mjs':
case 'cjs':
return JavaScriptIcon
case 'typescript':
case 'ts':
case 'mts':
case 'cts':
Expand Down

0 comments on commit 549eb71

Please sign in to comment.