# Best Practices for Navigation Commands

Navigation Commands are specialized interactions designed for surfaces that do not expose traditional UI elements such as maps, custom drawings, and canvas regions. Because these gestures bypass the standard UI tree, they require precise intent, clear direction, and unambiguous context to ensure deterministic execution. This section outlines best practices to help teams use MAP\_ACTION Tap and MAP\_ACTION Drag reliably, avoid misfires, and maintain stability across varying map layouts and dynamic surfaces.

### Recommended Best Practices for Writing Navigation Commands:

1. **Provide explicit start and end directions for drag**

   Example: MAP\_ACTION Drag from left to right to reposition marker
2. **Use intent context with map taps**\
   Example: MAP\_ACTION Tap on the red pickup marker near "City Center"
3. Prefer MAP\_ACTION only when element-based commands fail else for standard UI interaction, prefer tap/scroll/validate wherever possible
4. **Avoid overusing navigation gestures on standard screens**\
   Reserve for canvas and map surfaces
5. **Use clear directional semantics**\
   From left to right, from bottom to top, From top right to center of screen etc.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.drizz.dev/commands-reference/navigation-command/best-practices-for-navigation-commands.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
