Skip to content

feat: enhance search validation and descriptive error reporting#984

Open
johnnylemonny wants to merge 1 commit intopastelsky:bundlephobiafrom
johnnylemonny:feat/professionalization
Open

feat: enhance search validation and descriptive error reporting#984
johnnylemonny wants to merge 1 commit intopastelsky:bundlephobiafrom
johnnylemonny:feat/professionalization

Conversation

@johnnylemonny
Copy link
Copy Markdown

This Pull Request focuses on improving the robustness of the frontend and the clarity of server-side error messages, aimed at a more professional user experience.

Changes:

  • Search Validation: Added client-side checks to prevent empty or whitespace-only search queries, reducing unnecessary API traffic and providing instant feedback to users.
  • Improved Error Reporting: Refactored the error middleware to provide more granular feedback for BuildError and MissingDependencyError. Instead of generic messages, users now receive clearer hints on why a package might have failed to build.
  • TypeScript Foundation: Began aligning the utility modules with modern TypeScript standards to prevent runtime regressions and improve developer productivity.

Motivation

Improving the transparency of the build process helps users understand package issues (like missing peer dependencies) without needing to check server logs. Better validation prevents "ghost" searches and improves the overall feel of the UI.

Testing

  • Tested various failing packages to ensure new error messages are displayed correctly.
  • Verified that the search bar now correctly handles empty inputs.
  • Ran the existing test suite (pnpm test) to ensure no regressions in cached error handling.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant