Links & ReferencesLink to section
This page demonstrates the various types of links and references supported by the markdown system, including internal navigation, external links, and anchor references.
Basic Link TypesLink to section
Internal LinksLink to section
Internal links navigate within the site and use client-side routing:
- Home page - Link to the root
- Demo hub - Relative link to another page
- Contributing guide - Another internal page
- This very page - Self-reference
External LinksLink to section
External links automatically open in a new tab with security attributes:
- GitHub - Simple external link
- Anthropic - Company website
- MDN Web Docs - Developer resources
Notice the different behavior - external links have target="_blank"
and rel="noopener noreferrer"
added automatically.
Anchor LinksLink to section
Jump to sections within the same page:
Link SyntaxLink to section
Inline LinksLink to section
The most common markdown link format:
[Link text](https://example.com "Optional title")
Examples:
Reference-Style LinksLink to section
For cleaner markdown and reusable URLs:
[Link text][reference-key][Another link][reference-key]
[reference-key]: https://example.com "Optional title"
Example in practice:
Check out the tmuxp documentation for more information. You can also view the tmuxp API reference.
Automatic LinksLink to section
URLs and email addresses can be automatically linked:
<https://example.com>
Results:
Advanced Link PatternsLink to section
Links in ListsLink to section
Links work seamlessly within list structures:
- First item link - Navigate home
- Second item link - View demos
- Nested link - Typography showcase
- Another nested - Tables demo
- Third item link - Browse all pages
Links in TablesLink to section
Resource | Link | Description |
---|---|---|
Documentation | View Docs | Main documentation |
GitHub | Repository | Source code |
Support | Get Help | Support options |
Links with CodeLink to section
Combine links with inline code:
- Install via
npm install tmuxp
- View the
config.json
file - Read about
Array.prototype.map()
Link States and StylingLink to section
Visual IndicatorsLink to section
Links have different visual states:
- Normal: Standard link color
- Hover: Color change and underline
- Visited: Different color (in some contexts)
- Active: While being clicked
- Focus: Keyboard navigation highlight
Theme AdaptationLink to section
Links automatically adapt to the current theme:
- Light mode: Blue links with darker hover
- Dark mode: Lighter blue with appropriate contrast
Special Link TypesLink to section
Download LinksLink to section
Links to downloadable files:
[Download PDF](/files/document.pdf)[Get Source Code](/downloads/source.zip)
Tel and Mailto LinksLink to section
Special protocol links:
[Call us](tel:+1234567890)
Examples:
Fragment IdentifiersLink to section
Link to specific elements:
[Go to heading](#specific-heading)[Link with fragment](https://example.com#section)
Link AccessibilityLink to section
Descriptive Link TextLink to section
❌ Bad examples:
- Click here for more information
- Read more here
- Link
✅ Good examples:
Link ContextLink to section
Provide context for screen readers:
<a href="/docs" aria-label="View tmuxp documentation">Docs</a>
Keyboard NavigationLink to section
All links are keyboard accessible:
Tab
to navigate forwardShift + Tab
to navigate backwardEnter
to activate link
Reference Link ExamplesLink to section
Using reference-style links for cleaner markdown:
Popular projects include tmuxp, libvcs, and vcspull. These tools are part of the git-pull organization.
Security ConsiderationsLink to section
External Link SafetyLink to section
External links include security attributes:
<a href="https://external.com" target="_blank" rel="noopener noreferrer"> External Site</a>
target="_blank"
- Opens in new tabrel="noopener"
- Prevents window.opener accessrel="noreferrer"
- Doesn’t send referrer information
Best PracticesLink to section
- Use descriptive link text - Avoid generic “click here”
- Check link destinations - Ensure URLs are correct
- Consider link context - Surrounding text should make sense
- Test all links - Verify internal and external links work
- Provide alternatives - For important links, consider multiple paths
- Use HTTPS - Always prefer secure protocols
- Keep URLs stable - Avoid breaking existing links
Link TestingLink to section
Regular link checking ensures a good user experience:
- Internal links: Verified during build process
- External links: Periodic validation recommended
- Anchor links: Test after content changes
- Download links: Verify file availability