yuvrajkarna2717/react-hook-granth

[Feature]: Add useGeolocation hook

Open

#9 opened on Dec 6, 2025

 (0 comments) (0 reactions) (0 assignees)JavaScript (1 fork)auto 404
enhancementgood first issuehelp wanted

Repository metrics

Stars
 (3 stars)
PR merge metrics
 (PR metrics pending)

Description

Description: Create a hook for accessing browser geolocation API with proper error handling and loading states.

Requirements:

  • Get current position
  • Watch position changes
  • Handle permissions and errors
  • Loading states

API Proposal:

const { position, error, loading, getCurrentPosition } = useGeolocation();

Contributor guide