SAP Home Learn Build Integrate Model Operate Extend with AI ConnectTutorial navigator Knowledge Graph API Devtoberfest Developer Advocates App Space

Manage my Account SAP Devs YouTube ↗ Learnings ↗ Community ↗ Provide Feedback ↗
Logout
โคข Open full site

Add Routing to a UI5 Web Components for React Project

Use routes to navigate between different pages using UI5 Web Components for React.

Overview

🎓 beginner 15 min. HTML5BeginnerSAP Fiori

You will learn

  • โœ”How to refactor code into different React components
  • โœ”How to create multiple pages
  • โœ”How to use routing
Lukas Harbarth L Lukas Harbarth April 16, 2025
Created by December 5, 2019
Contributors

Prerequisites

Steps

Intro

In this tutorial, you will learn how to create routes to different paths of your application using React Router. For this you will create a new page and set up routing between the page and the dashboard.


Step 1 Create a Detail page
โ€”

In src create a Detail.tsx file.

Inside of that file, create the Detail component that will return a title to your liking.

TypeScript
import { Title } from "@ui5/webcomponents-react";

export function Detail() {
  return <Title>Hello World!</Title>;
}
Step 2 Add Router
+
Step 3 Create Home component
+
Step 4 Import Router components
+
Step 5 Handle navigation
+
Step 6 Code overview
+

Resources

Discussion

Share feedback on this tutorial or join the conversation in SAP Community.

Submit detailed feedback Discuss in Community
Steps
Step 1 of 6
1. Create a Detail page 2. Add Router 3. Create Home component 4. Import Router components 5. Handle navigation 6. Code overview

Learn more →