Skip to content

Commit 8760b4a

Browse files
committed
Update shareContent function to include organizer and title in share text
1 parent 12e5982 commit 8760b4a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/Page/OpportunitiesHub/BootcampsList.jsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ import styled from 'styled-components';
33
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
44
import { faFlag, faMapMarkerAlt, faCalendarAlt, faShareAlt } from '@fortawesome/free-solid-svg-icons';
55

6-
const shareContent = (url) => {
6+
const shareContent = (url, organizer, title) => {
77
if (navigator.share) {
88
navigator
99
.share({
10-
title: '',
11-
text: '',
10+
title: title,
11+
text: `Check out this bootcamp organized by ${organizer}!`,
1212
url: url,
1313
})
1414
.then(() => console.log('Successful share'))

0 commit comments

Comments
 (0)