Skip to content

Commit

Permalink
Update CodeBlock.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
sxjeru authored Aug 7, 2024
1 parent 79cd6c5 commit 45623eb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Markdown/CodeBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const useCode = (raw: any) => {

if (!children) return;

const content = (Array.isArray(children) ? (children[0] as string) : children).trim();
const content = (Array.isArray(children) ? (children[0] as string) : children);

Check warning on line 20 in src/Markdown/CodeBlock.tsx

View check run for this annotation

Codecov / codecov/patch

src/Markdown/CodeBlock.tsx#L20

Added line #L20 was not covered by tests

const lang = className?.replace('language-', '') || FALLBACK_LANG;

Expand Down

0 comments on commit 45623eb

Please sign in to comment.