ReactJS Semantic UI Breadcrumb Collections
Last Updated :
17 Jun, 2021
Semantic UI is a modern framework used in developing seamless designs for the website, It gives the user a lightweight experience with its components. It uses the predefined CSS, JQuery language to incorporate in different frameworks.
In this article we will know how to use breadcrumb collections in ReactJS Semantic UI.
Breadcrumb is used to show hierarchy between content.
Syntax:
<Breadcrumb>
<Breadcrumb.divider/>
</Breadcrumb>
Creating React Application And Installing Module:
Project Structure: It will look like the following.
Step to Run Application: Run the application from the root directory of the project, using the following command.
npm start
Example 1: In this example, we will be going to use a basic breadcrumb element to show the hierarchy between content by using ReactJS Semantic UI Breadcrumb collections.
App.js
import React from 'react'
import {Breadcrumb} from 'semantic-ui-react'
const styleLink = document.createElement("link");
styleLink.rel = "stylesheet";
styleLink.href =
"https://cdn.jsdelivr.net/npm/semantic-ui/dist/semantic.min.css";
document.head.appendChild(styleLink);
const Btt = () =>(
<Breadcrumb>
<Breadcrumb.Section active>One</Breadcrumb.Section>
<Breadcrumb.Divider icon='angle right'/>
<Breadcrumb.Section active>Two</Breadcrumb.Section>
<Breadcrumb.Divider icon='angle right' />
<Breadcrumb.Section active>Three</Breadcrumb.Section>
<Breadcrumb.Divider icon='angle right' />
<Breadcrumb.Section active>Four</Breadcrumb.Section>
<Breadcrumb.Divider icon='angle right' />
<Breadcrumb.Section active>Five</Breadcrumb.Section>
</Breadcrumb>
)
export default Btt
Output:
Example 2: In this example, we will be going to use a breadcrumb element containing divider to show the relationship between sections by using ReactJS Semantic UI Breadcrumb collections.
App.js
import React from 'react'
import {Breadcrumb} from 'semantic-ui-react'
const styleLink = document.createElement("link");
styleLink.rel = "stylesheet";
styleLink.href =
"https://cdn.jsdelivr.net/npm/semantic-ui/dist/semantic.min.css";
document.head.appendChild(styleLink);
const Btt = () =>(
<Breadcrumb>
<Breadcrumb.Section active>One</Breadcrumb.Section>
<Breadcrumb.Divider>/</Breadcrumb.Divider>
<Breadcrumb.Section active>Two</Breadcrumb.Section>
<Breadcrumb.Divider>/</Breadcrumb.Divider>
<Breadcrumb.Section active>Three</Breadcrumb.Section>
<Breadcrumb.Divider>/</Breadcrumb.Divider>
<Breadcrumb.Section active>Four</Breadcrumb.Section>
<Breadcrumb.Divider>/</Breadcrumb.Divider>
<Breadcrumb.Section active>Five</Breadcrumb.Section>
</Breadcrumb>
)
export default Btt
Output:
Reference: https://react.semantic-ui.com/collections/breadcrumb
Similar Reads
ReactJS Semantic UI Menu Collections Semantic UI is a modern framework used in developing seamless designs for the website, It gives the user a lightweight experience with its components. It uses the predefined CSS, JQuery language to incorporate in different frameworks. In this article we will know how to use Menu Collections in React
3 min read
ReactJS Semantic UI Grid Collections Semantic UI is a modern framework used in developing seamless designs for the website, It gives the user a lightweight experience with its components. It uses the predefined CSS, JQuery language to incorporate in different frameworks. In this article we will know how to use grid collections in React
2 min read
Semantic-UI Breadcrumb Section Content Semantic UI is an open-source development framework that provides pre-defined classes to make our website look beautiful, amazing, and responsive. It is similar to Bootstrap which has predefined classes. It uses jQuery and CSS to create the interfaces. It can also be directly used via CDN like boots
2 min read
Semantic-UI Breadcrumb Content Semantic UI is an open-source framework that uses CSS and jQuery to build great user interfaces. It is the same as a bootstrap for use and has great different elements to use to make your website look more amazing. Semantic UI offers a Breadcrumb component for users to display order or rank in conte
2 min read
ReactJS Semantic UI Table Collections Semantic UI is a modern framework used in developing seamless designs for the website, It gives the user a lightweight experience with its components. It uses the predefined CSS, JQuery language to incorporate in different frameworks. In this article we will know how to use table collections in Reac
3 min read
ReactJS Semantic UI Message Collection Semantic UI is a modern framework used in developing seamless designs for the website, It gives the user a lightweight experience with its components. It uses the predefined CSS, JQuery language to incorporate in different frameworks. In this article we will know how to use message collections in Re
2 min read