Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/platforms/react-native/build-distribution/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Build Distribution
sidebar_title: Build Distribution
sidebar_order: 5250
sidebar_order: 10
sidebar_section: configuration
description: Upload React Native iOS and Android builds to Sentry for distribution to internal teams and beta testers.
---

Expand Down
6 changes: 4 additions & 2 deletions docs/platforms/react-native/configuration/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
---
title: Configuration
title: Extended Configuration
sidebar_title: Extended Configuration
description: "Additional configuration options for the SDK."
sidebar_order: 5
sidebar_order: 2
sidebar_section: configuration
---

<PageGrid />
3 changes: 2 additions & 1 deletion docs/platforms/react-native/data-management/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Data Management
description: Manage your events by pre-filtering, scrubbing sensitive information, and forwarding them to other systems.
sidebar_order: 2500
sidebar_order: 4
sidebar_section: configuration
---

<PageGrid />
3 changes: 2 additions & 1 deletion docs/platforms/react-native/enriching-events/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Enriching Events
description: Enrich events with additional context to make debugging simpler.
sidebar_order: 2300
sidebar_order: 1
sidebar_section: configuration
---

<PageGrid />
3 changes: 2 additions & 1 deletion docs/platforms/react-native/feature-flags/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Set Up Feature Flags
sidebar_title: Feature Flags
sidebar_order: 7000
sidebar_order: 11
sidebar_section: features
description: Generic Feature Flags Integration.
---

Expand Down
1 change: 1 addition & 0 deletions docs/platforms/react-native/features/index.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Features
sidebar_order: 1
sidebar_hidden: true
description: "Learn about the features of Sentry's React Native SDK."
---

Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/integrations/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Integrations
description: "Learn more about how integrations extend the functionality of our SDK and automatically cover common libraries and environments."
sidebar_order: 30
sidebar_order: 3
sidebar_section: configuration
---

<PageGrid />
4 changes: 3 additions & 1 deletion docs/platforms/react-native/logs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
title: Set Up Logs
sidebar_title: Logs
description: "Structured logs allow you to send, view and query logs sent from your applications within Sentry."
sidebar_order: 5755
sidebar_order: 4
sidebar_section: features
new: true
---

<PlatformContent includePath="llm-rules-logs" />
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/metrics/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
title: Set Up Metrics
sidebar_title: Metrics
description: "Metrics allow you to send, view and query counters, gauges and measurements from your Sentry-configured apps to track application health and drill down into related traces, logs, and errors."
sidebar_order: 5760
sidebar_order: 6
sidebar_section: features
beta: true
---

Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/migration/index.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Migration Guide
sidebar_order: 8000
sidebar_order: 11
sidebar_section: configuration
description: "Learn how to migrate to the new versions of Sentry's React Native SDK."
---

Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/overhead/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: SDK Overhead
description: "Learn about Sentry's React Native SDK overhead and how you can tailor your configuration to minimize it."
sidebar_order: 7500
sidebar_order: 9
sidebar_section: configuration
---

Adding new features or dependencies to your app incurs additional costs on resources - CPU time, memory usage, and network bandwidth, among other things. Sentry SDKs are no different. This document adds transparency to the possible overhead that using our SDK can add, and help you find the feature set and configurations that work best for you.
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/profiling/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
title: Set Up Profiling
sidebar_title: Profiling
description: "Learn how to enable profiling in your app if it is not already set up."
sidebar_order: 5000
sidebar_order: 3
sidebar_section: features
---

<PlatformContent includePath="profiling/index/why-profiling" />
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/releases/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Mobile SDK Releases
description: "Learn about Sentry's release channels for Mobile SDK updates."
sidebar_order: 7000
sidebar_order: 8
sidebar_section: configuration
---

The React Native SDK uses the following channels to release SDK updates:
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/session-replay/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Set Up Session Replay
sidebar_title: Session Replay
sidebar_order: 5500
sidebar_order: 5
sidebar_section: features
notSupported:
description: "Learn how to enable Session Replay in your mobile app."
---
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/size-analysis/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Size Analysis
sidebar_title: Size Analysis
sidebar_order: 5200
sidebar_order: 12
sidebar_section: features
description: Upload React Native iOS and Android builds to Sentry for size analysis.
---

Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/sourcemaps/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Source Maps
description: "Learn more about how to upload your source maps to Sentry."
sidebar_order: 95
sidebar_order: 5
sidebar_section: configuration
---

<Alert>
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/tracing/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
title: Set Up Tracing
sidebar_title: Tracing
description: "Learn how to enable tracing in your app and discover valuable performance insights of your application."
sidebar_order: 4000
sidebar_order: 2
sidebar_section: features
---

With [tracing](/product/insights/overview/), Sentry tracks your software performance, measuring metrics like throughput and latency, and displaying the impact of errors across multiple systems. Sentry captures distributed traces consisting of transactions and spans, which measure individual services and individual operations within those services. Learn more about our model in [Distributed Tracing](/product/sentry-basics/tracing/distributed-tracing/).
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/troubleshooting/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Troubleshooting
description: "Troubleshoot and resolve common issues with the React Native SDK."
sidebar_order: 9000
sidebar_order: 12
sidebar_section: configuration
---

## Support 16 KB Page Sizes on Android
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/upload-debug/index.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Debug Symbols
sidebar_order: 96
sidebar_order: 7
sidebar_section: configuration
description: "Learn about using the Sentry Gradle Plugin or sentry-cli for providing debug symbols to Sentry."
---

Expand Down
5 changes: 3 additions & 2 deletions docs/platforms/react-native/usage/index.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: Usage
title: Capturing Errors
description: "Use the SDK to manually capture errors and other events."
sidebar_order: 10
sidebar_order: 1
sidebar_section: features
---

Sentry's SDK hooks into your runtime environment and automatically reports errors, uncaught exceptions, and unhandled rejections as well as other types of errors depending on the platform.
Expand Down
3 changes: 2 additions & 1 deletion docs/platforms/react-native/user-feedback/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
title: Set Up User Feedback
sidebar_title: User Feedback
description: Learn how to enable User Feedback in your app.
sidebar_order: 6000
sidebar_order: 10
sidebar_section: features
og_image: /og-images/platforms-react-native-user-feedback.png
---

Expand Down
42 changes: 34 additions & 8 deletions src/components/sidebar/dynamicNav.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {Fragment} from 'react';
import Link from 'next/link';

import {serverContext} from 'sentry-docs/serverContext';
import {sortPages} from 'sentry-docs/utils';
Expand All @@ -13,6 +14,11 @@ const SECTION_LABELS: Record<string, string> = {
configuration: 'Configuration',
};

// Section links configuration - sections that should be clickable headers
const SECTION_LINKS: Record<string, string> = {
features: 'features',
};

const SECTION_ORDER = ['features', 'configuration'] as const;

type Node = {
Expand Down Expand Up @@ -73,7 +79,8 @@ export const renderChildren = (
exclude: string[],
path: string,
showDepth: number = 0,
depth: number = 0
depth: number = 0,
rootPath?: string
): React.ReactNode[] => {
const sortedChildren = sortPages(
children.filter(
Expand Down Expand Up @@ -124,7 +131,7 @@ export const renderChildren = (
beta={node.context.beta}
isNew={node.context.new}
>
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1)}
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1, rootPath)}
</CollapsibleSidebarLink>
);

Expand All @@ -146,13 +153,22 @@ export const renderChildren = (
result.push(<SidebarSeparator key={`sep-${sectionKey}`} />);
}

// Add section header
// Add section header (with optional link)
const sectionLink = SECTION_LINKS[sectionKey];
const sectionHref = sectionLink && rootPath ? `/${rootPath}/${sectionLink}/` : null;

result.push(
<li
key={`header-${sectionKey}`}
className="sidebar-section-header text-xs font-semibold text-gray-11 uppercase tracking-wider px-2 py-2 mt-2"
>
{SECTION_LABELS[sectionKey]}
{sectionHref ? (
<Link href={sectionHref} className="hover:text-purple no-underline">
{SECTION_LABELS[sectionKey]}
</Link>
) : (
SECTION_LABELS[sectionKey]
)}
</li>
);

Expand All @@ -172,7 +188,7 @@ export const renderChildren = (
beta={node.context.beta}
isNew={node.context.new}
>
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1)}
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1, rootPath)}
</CollapsibleSidebarLink>
);

Expand All @@ -199,7 +215,7 @@ export const renderChildren = (
beta={node.context.beta}
isNew={node.context.new}
>
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1)}
{renderChildren(nodeChildren, exclude, path, showDepth, depth + 1, rootPath)}
</CollapsibleSidebarLink>
);
});
Expand All @@ -212,11 +228,20 @@ type ChildrenProps = {
path: string;
tree: EntityTree[];
exclude?: string[];
rootPath?: string;
showDepth?: number;
};

export function Children({tree, path, exclude = [], showDepth = 0}: ChildrenProps) {
return <Fragment>{renderChildren(tree, exclude, path, showDepth)}</Fragment>;
export function Children({
tree,
path,
exclude = [],
showDepth = 0,
rootPath,
}: ChildrenProps) {
return (
<Fragment>{renderChildren(tree, exclude, path, showDepth, 0, rootPath)}</Fragment>
);
}

type Props = {
Expand Down Expand Up @@ -304,6 +329,7 @@ export function DynamicNav({
exclude={exclude}
showDepth={0}
path={linkPath}
rootPath={root}
/>
</ul>
)}
Expand Down
Loading