Skip to content

Fix content rendering crash by adding safety checks for non-string an…#168

Merged
ItsVikasA merged 1 commit into
ItsVikasA:mainfrom
VishalRaut2106:fix/issue-140-rendering-crash
Feb 24, 2026
Merged

Fix content rendering crash by adding safety checks for non-string an…#168
ItsVikasA merged 1 commit into
ItsVikasA:mainfrom
VishalRaut2106:fix/issue-140-rendering-crash

Conversation

@VishalRaut2106
Copy link
Copy Markdown
Contributor

Description

This PR addresses client-side crashes that occurred when the AI returned malformed content (non-string or null) for the 'para' type in chapters.

Key Changes

  • Modified src/components/chapter_content/Content.jsx to safely handle item.content using type checking and array joining.
  • Updated src/components/MarkDown.jsx to ensure content is always a string by providing a default empty string.

Verification Plan

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Feb 23, 2026

@VishalRaut2106 is attempting to deploy a commit to the Vikas' projects Team on Vercel.

A member of the Team first needs to authorize it.

@ItsVikasA ItsVikasA merged commit a36ca00 into ItsVikasA:main Feb 24, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Application error: a client-side exception has occurred while loading innovision-open-source.vercel.app (see the browser console for more information).

2 participants