Features
Ce contenu n’est pas encore disponible dans votre langue.
Fuzzy Search
Section titled “Fuzzy Search”The plugin uses Fuse.js for fuzzy matching. Users can find pages with typos or partial queries.
Ranking
Section titled “Ranking”Results are ranked by:
- Exact title matches
- Title prefix matches (e.g., “get” → “Getting Started”)
- Word-start matches (e.g., “auth” → “OAuth Authentication”)
- Fuse.js fuzzy score
Matching text is highlighted using <mark class="telescope__highlight">.
Configuration
Section titled “Configuration”The threshold option (0.0–1.0) controls match strictness. Lower values require closer matches.
0.0: Exact matches only0.3: Minor typos allowed (default)0.6+: Lenient matching
Other options include distance, ignoreLocation, and keys. See Configuration → fuseOptions for details.
Performance
Section titled “Performance”For large sites (500+ pages), increase debounceMs to 150–200ms and consider setting ignoreLocation: false. Defaults work well up to ~1000 pages.
Pinned Pages
Section titled “Pinned Pages”Pinned pages appear at the top of the search modal, above recent pages and search results. They persist across sessions.
- Keyboard: Navigate to a result, press Space
- Mouse: Click the bookmark icon
Pinned pages show a filled bookmark icon. Unpinned pages show an outline.
Storage
Section titled “Storage”Stored in localStorage under telescope_pinnedPages. Click Clear to remove all pins.
Customization
Section titled “Customization”Change the pin color via config or CSS:
starlightTelescope({ theme: { pinColor: '#f59e0b' }}):root { --telescope-pin-color: #ec4899;}Recent Pages
Section titled “Recent Pages”Pages visited via the search modal are tracked and displayed in a “Recently Visited” section. The modal also has a dedicated “Recent” tab.
Behavior
Section titled “Behavior”- Pages are added when navigating via search modal
- Most recent pages appear first
- History persists across sessions via
localStorage - Pages are validated against current site content on load
Storage
Section titled “Storage”Stored in localStorage under telescope_recentPages. Click Clear to remove all recent pages.
Configuration
Section titled “Configuration”Set recentPagesCount to control how many pages are shown (0–20). Set to 0 to disable. See Configuration → recentPagesCount.
Locale Behavior
Section titled “Locale Behavior”Both pinned and recent pages are locale-aware. Pages saved in English only appear when viewing English docs. See Internationalization for details.