Skip to content

[BUG] : Redundant event listeners, duplicate JSX wrapper injections, and a missing global isMobile state causing layout breakage #98

Description

@Subha12125

Description

While reviewing the codebase, I identified serious structural bugs and code redundancies inside app/page.tsx. Currently, the layout handles split pane scaling for desktop vs mobile device screens, but it breaks due to an undeclared/missing variable isMobile inside the main JSX block and completely duplicated structural segments.


🐛 Found Bugs & Bloat

1. Missing isMobile Variable Reference

In the layout conditional rendering blocks of app/page.tsx, the code attempts to set responsive widths and heights:

style={
  layout === "split"
    ? {
      width: isMobile ? "100%" : `${splitRatio}%`,
      height: isMobile ? `${splitRatio}%` : "100%",
    }
    : { height: "100%", width: "100%" }
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions