Powerful code navigation system that allows you to quickly locate and browse code in large projects, with support for cross-file analysis and intelligent reference finding.
Go to Definition
Quickly navigate to where symbols are defined.
F12 or Cmd/Ctrl + Click Position your cursor on any variable, function, class, or type and press F12 to jump to its definition. local utils = require ( "utils.string" )
-- Press F12 on 'formatName' to jump to definition
local result = utils . formatName ( "john" )
Alt + F12 or Option + F12 View the definition in a popup without leaving your current location. local config = require ( "config" )
-- Peek definition shows the config module inline
local timeout = config . timeout
Features:
Inline popup preview
Edit definitions without navigating away
Multiple definitions shown if available
Special Navigation Features
Navigate to module files from require statements: -- Click or F12 on the string to open the module file
local parser = require ( "lib.parser" )
local utils = require ( "utils/string" )
Supports:
Dot notation: require("lib.parser")
Slash notation: require("lib/parser")
Relative paths: require("./local_module")
Navigate to files from path strings: -- F12 on the path string opens the file
local config_path = "./config/settings.lua"
local data = loadfile ( "../data/users.dat" )
Navigate from EmmyLua @see tags: --- @see utils.formatString For string formatting
--- @see User User class definition
local function processData ()
-- F12 on the @see reference navigates to target
end
Navigate to overloaded function definitions: --- @overload fun ( name : string ): User
--- @overload fun ( id : number ): User
--- @param identifier string | number
--- @return User
local function getUser ( identifier )
-- F12 on @overload tag shows all overload definitions
end
Find References
Locate all places where a symbol is used.
Standard References
String References
Fuzzy References
Shift + F12 or right-click → Find All References --- @class User
local User = {}
function User : new ( name )
-- Find all references to 'User' class
end
Shows:
All usages in current file
All usages across workspace
Grouped by file
Preview of surrounding code
Find usage locations of string literals: -- Enable string reference finding in config
local EVENT_NAME = "user:login"
-- Find all places where "user:login" is used
emit ( "user:login" , userData )
Features:
Exact string matching
Useful for event names, constants
Can be enabled/disabled in configuration
Smart matching for undefined variables: -- Even without strict definitions, find related usages
myGlobalVar = 42
-- Find references uses smart inference
print ( myGlobalVar )
Configuration: {
"references" : {
"fuzzy" : true ,
"string" : true
}
}
Reference finding supports cross-file analysis and can accurately identify dependencies between modules.
Document Symbols
Structured view of symbols in the current file.
Access Methods
Outline Panel View in the left sidebar for hierarchical navigation
Quick Open Press Ctrl/Cmd + Shift + O for quick symbol search
Symbol Types
-- Functions
local function processData () end
-- Classes
--- @class Vehicle
local Vehicle = {}
-- Methods
function Vehicle : start () end
-- Fields
Vehicle . speed = 0
-- Variables
local count = 0
-- Constants
local MAX_SIZE = 100
All of these are shown in the document symbols view with:
Hierarchical structure
Type information
Scope indicators
Icon differentiation
Real-time Filtering
Ctrl+Shift+O → Type 'proc' → Instantly shows 'processData'
Features:
Fuzzy matching
Instant results
Type-ahead filtering
Workspace Symbol Search
Global symbol search across your entire workspace.
Quick Access
Smart Features
Preview
Ctrl/Cmd + T - Open workspace symbol searchType symbol name or prefix with @ for symbol-only search: @User → Find all User classes
@process → Find all symbols containing 'process'
formatString → Find formatString function
Fuzzy Matching Type: 'usrctrl' → Matches: 'UserController'
Type: 'cfg' → Matches: 'Config', 'configuration'
Result Sorting
By relevance
By usage frequency
By file location
By symbol type
Type Filtering
Functions
Variables
Classes
Methods
Fields
Each result shows:
Symbol name and type
File location
Code preview
Namespace/module context
UserController : login ()
└─ src / controllers / user . lua : 42
function UserController : login ( username , password )
Semantic Highlighting
Advanced syntax highlighting based on LSP semantic tokens.
Token Analysis
Variable types (local, global, parameter)
Function definitions and calls
Lua keywords
Documentation comments
Visual Distinction
Type-based colors
Scope depth indication
Error highlighting (red)
Warning highlighting (yellow)
Enhanced Rendering
local mutable_var = 10 -- Mutable: underlined
local const_value = 42 -- Constant: normal display
--- @type string
local typed_var = "text" -- Type-aware coloring
Features:
Mutable variable underlining
Type-based coloring
Real-time updates
Scope-aware highlighting
Inlay Hints
Display useful type and status information inline without mouse hovering.
Parameter Types
Variable Types
Override Markers
function greet ( name , age , active )
-- ^string ^number ^boolean
print ( name .. " is " .. age )
end
Shows parameter types inline for better readability. local count = 42 -- : number
local name = "John" -- : string
local items = { 1 , 2 , 3 } -- : number[]
Displays inferred types for local variables. --- @class Animal
local Animal = {}
function Animal : speak () end
--- @class Dog : Animal
local Dog = {}
function Dog : speak () -- ⟨override⟩
print ( "Woof!" )
end
Indicates when methods override parent class methods.
Configuration
{
"inlayHints" : {
"enable" : true ,
"paramHint" : true ,
"indexHint" : true ,
"localHint" : false ,
"overrideHint" : true
}
}
Document Highlighting
Highlight all occurrences of the symbol under the cursor.
Reference Highlighting
Keyword Groups
local function calculate ( value )
-- ^^^^^ selected
local result = value * 2
-- ^^^^^ highlighted
return value + result
-- ^^^^^ highlighted
end
Features:
Highlights all uses of same variable
Shows effective scope
Real-time updates on cursor move
if condition then
-- ^^ selected
processData ()
elseif otherCondition then
-- highlighted
handleOther ()
else
-- highlighted
defaultAction ()
end
-- highlighted
Paired highlighting for:
if-then-elseif-else-end
for-do-end
while-do-end
function-end
Navigation Best Practices
Use Keyboard Shortcuts
Master the key combinations for faster navigation:
F12 - Go to Definition
Shift + F12 - Find References
Ctrl/Cmd + Shift + O - Document Symbols
Ctrl/Cmd + T - Workspace Symbols
Leverage Peek Features
Use Peek Definition (Alt + F12) to view code without losing context.
Annotate Your Code
Add EmmyLua annotations for better navigation accuracy: --- @class Config
--- @field timeout number
--- @field retries number
local Config = {}
Use Breadcrumbs
Enable breadcrumbs in your editor for hierarchical navigation context.
All navigation features support cross-file analysis and can accurately identify dependencies between modules.