Bookmarks are useful for:
- Marking important model definitions
- Tagging sections that need review or optimization
- Creating quick access to frequently referenced code
- Building a custom navigation system for large projects
Managing Bookmarks
Adding Bookmarks
- Highlight a block of code you want to bookmark
- Right-click on the highlighted code
- Hover over Bookmarks and select the Toggle command
- A bookmark ribbon will appear next to the code block
Use Toggle Labeled Bookmark to assign a label to the bookmark for additional context. This makes it easier to identify the purpose of each bookmark at a glance.
Navigating Bookmarks
Using Menus:- Right-click and hover over Bookmarks
- Click Jump to Previous or Jump to Next
- MacOS:
⌥ ⌘ Lto Jump to Next⌥ ⌘ Jto Jump to Previous
- Windows:
F2to Jump to NextShift+F2to Jump to Previous
- Open the Bookmarks tab from the left-hand panel to view and manage all bookmarks
- Click on any bookmark in the list to jump directly to that location in your code
- Edit bookmark labels as needed by clicking on the label in the Bookmarks tab
Deleting Bookmarks
You can remove bookmarks in several ways:- From the editor: Right-click the blue bookmark ribbon next to the code and select Remove Bookmark
- From the Bookmarks tab:
- Click the X button next to a specific bookmark to remove it
- Click the Clear icon to remove all bookmarks from a specific file
- Toggle method: Right-click on bookmarked code and use the Toggle command again to remove the bookmark
Best PracticesCommand Usage
- Use Toggle Labeled Bookmark to add meaningful labels that describe the purpose of the bookmarked section
- Regularly clear outdated bookmarks to maintain a clean and organized workspace
- Use consistent naming conventions for bookmark labels to make them easier to scan
- Bookmark key SQL transformations and tests in your dbt models for easy navigation
- Create bookmarks for:
- Model definitions
- Complex joins
- Custom macros
- Test definitions
- Utilize the “Explorer” section of the Bookmarks tab to get an overview of all bookmarked sections in your project
- Combine bookmarks with other IDE features like Search for powerful project navigation