AddThisFeature

Store Locator

Help visitors find the nearest branch, with hours, directions, and a way to get in touch.

moderate Search & Discovery

What it adds

A searchable list of physical locations with distance, opening hours, contact details, and a map view.

What your agent is told to do

5
  1. 1

    Build the list first and the map second. The list of nearest locations with address, distance, hours, and phone number is the feature; the map is a way to scan it.

  2. 2

    Offer to use the visitor's device location and always offer a text field for a postcode, town, or address alongside it. Never make the location prompt the only route in.

  3. 3

    Store opening hours per location with the location's own time zone, including regular weekly hours and dated exceptions for holidays and one-off closures, and compute open or closed from those.

  4. 4

    If the app already has Google Places Address Lookup, Mapbox Geocoding, or Address Autocomplete, use them to turn the typed query into coordinates. Do not add a second geocoding path for this one screen.

  5. 5

    Do not require the map to render before results appear. Fetch and show the ranked list from the server, then enhance with the map, so a blocked or failed map script leaves a working page.

Edge cases it handles

8
  • Location permission is often denied or unavailable. Fall back immediately to the manual entry field with a plain explanation rather than leaving a spinner or a permission prompt the visitor already dismissed.
  • A search can legitimately return nothing within the radius. Say that no location is within the distance searched, offer the nearest one beyond it, and never present an empty list as an error.
  • Open or closed must be computed in the location's own time zone against its holiday exceptions, not the visitor's clock. A branch shown as open on a public holiday sends someone to a locked door.
  • Filtering must apply to the map and the list together. Panning the map should update the list, and narrowing the list should update the pins, or the two views will disagree about what exists.
  • Map tiles are heavy and are blocked on some networks and by some extensions. The page must remain fully usable with addresses, hours, and directions links when the map never loads.
  • Directions should hand off to the visitor's own maps application with the destination pre-filled, rather than attempting turn-by-turn routing in the page.
  • Each result needs a phone number that dials on mobile and an address that is selectable as text, because people copy addresses more often than they click through.
  • Locations that are temporarily closed or not yet open need their own state, distinct from closed-for-the-evening.

Definition of done

8
  • Results are ranked by distance from either a detected location or a typed query.
  • Denied location permission leads straight to manual entry with no dead end.
  • Open and closed status is correct for the location's time zone and its holiday exceptions.
  • The map and the result list always show the same set of locations.
  • The page lists locations, hours, and directions links with the map unavailable.
  • An empty radius result explains itself and offers the nearest location beyond it.
  • The feature matches the existing design system.
  • No existing functionality is broken.

Related features

How it works

  1. 1

    Copy the link

    Grab the Markdown instruction URL for this feature.

  2. 2

    Give it to your AI

    Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.

  3. 3

    It inspects, then implements

    Your agent reads your existing app first, then adds the feature to fit it.

Works with your stack

These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.

Need it tighter than that? Customize the feature and tell it exactly what you're running.