Skip to main content

Command Palette

Search for a command to run...

How to use react-bootstrap-icons ?

Published
1 min read
How to use react-bootstrap-icons ?
S

I love learning about technology and sharing that with others

  1. install react-bootstrap-icons dependency

npm i react-bootstrap-icons

2. Navigate to the website : https://icons.getbootstrap.com/#usage

to see all the icons that we can use

3. Let say we wants to use the icon called as trash

so lets see how we can use this in our component

  • here we have imported the icon that we need like “trash”
  • and then we added it as a componentt
  • we can give any color , size and we can send it as a prop in the component.

import React from ‘react’

import { Trash } from ‘react-bootstrap-icons’

import { PencilSquare } from ‘react-bootstrap-icons’

function milestone() {

return (

)

}

export default milestone

25 views

More from this blog

H

hashcodehub

271 posts

Consistent, Passionate and Organized :)