Skip to content

Add PropTypes validation to Navbar and CartDrawer#670

Open
ananyasingh180306-ctrl wants to merge 2 commits into
parthbuilds-community:mainfrom
ananyasingh180306-ctrl:add-proptypes-navbar-cartdrawer
Open

Add PropTypes validation to Navbar and CartDrawer#670
ananyasingh180306-ctrl wants to merge 2 commits into
parthbuilds-community:mainfrom
ananyasingh180306-ctrl:add-proptypes-navbar-cartdrawer

Conversation

@ananyasingh180306-ctrl

Copy link
Copy Markdown

📋 What does this PR do?

Adds runtime prop validation using prop-types for the Navbar and CartDrawer components.

Changes made:

  • Installed prop-types dependency
  • Added PropTypes definitions to Navbar.jsx
  • Added PropTypes definitions to CartDrawer.jsx

Benefits:

  • Improves developer experience
  • Makes expected component props easier to understand
  • Provides runtime warnings when incorrect prop types are passed during development
  • Helps prevent silent prop-related bugs

Closes #57
📋 What does this PR do?

Adds runtime prop validation using prop-types for the Navbar and CartDrawer components.

🧪 How was this tested?

  • Installed prop-types successfully
  • Started the application locally using npm run dev
  • Verified the application loads without build errors
  • Confirmed PropTypes definitions are present for all component props in Navbar.jsx and CartDrawer.jsx

📸 Screenshots (if UI changes)

No UI changes were made.

✅ Checklist

  • I've read the CONTRIBUTING guide
  • My code follows the project's style guidelines
  • I've tested my changes locally
  • I've linked the related issue
  • I haven't introduced any new secrets or API keys

@github-actions github-actions Bot added documentation Improvements or additions to documentation enhancement New feature or request refactor Improve code without changing functionality UI UI-related improvements including layouts, responsiveness, styling, animations, and UX enhancements. frontend labels Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request frontend refactor Improve code without changing functionality UI UI-related improvements including layouts, responsiveness, styling, animations, and UX enhancements.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: add prop-types validation to Navbar and CartDrawer

1 participant