Skip to content

[BUG] ReadingTime Component Loads on Non-Content Pages #332

Description

@sahitya0xsingh

Description

The ReadingTime component appears to be loading and executing on pages where no actual reading content is present, such as quiz or bookmark pages. This unnecessary loading causes redundant DOM queries and calculations, potentially impacting page performance and user experience. The component should only be active on pages that display textual content for reading.

Steps to Reproduce

  1. Navigate to a quiz page or a bookmark page (or any page without primary textual content).
  2. Open developer tools and inspect the loaded components or network activity.
  3. Observe that the ReadingTime component's logic is being executed, even though there's no relevant content to calculate reading time for.

Expected Behavior

What should happen?
The ReadingTime component should only load and perform its calculations on pages that contain substantial textual content for which reading time is relevant. It should be disabled or not rendered on pages like quizzes, bookmarks, or other non-content views.

Environment

  • Browser: Chrome 120+, Firefox 120+, Safari 17+
  • Device: Desktop/Laptop, Mobile (iOS/Android)
  • OS: Windows 10/11, macOS 14+, Linux, iOS 17+, Android 13+

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions