Skip to content

Commit

Permalink
refactor: use helmet for document title
Browse files Browse the repository at this point in the history
  • Loading branch information
navinkarkera committed Dec 11, 2023
1 parent eb30b06 commit 6567ed9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/course-outline/CourseOutline.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
Layout,
TransitionReplace,
} from '@edx/paragon';
import { Helmet } from 'react-helmet';
import {
Add as IconAdd,
CheckCircle as CheckCircleIcon,
Expand Down Expand Up @@ -71,8 +72,6 @@ const CourseOutline = ({ courseId }) => {
handleNewSectionSubmit,
} = useCourseOutline({ courseId });

document.title = getPageHeadTitle(courseName, intl.formatMessage(messages.headingTitle));

const {
isShow: isShowProcessingNotification,
title: processingNotificationTitle,
Expand All @@ -85,6 +84,9 @@ const CourseOutline = ({ courseId }) => {

return (
<>
<Helmet>
<title>{getPageHeadTitle(courseName, intl.formatMessage(messages.headingTitle))}</title>
</Helmet>
<Container size="xl" className="px-4">
<section className="course-outline-container mb-4 mt-5">
<TransitionReplace>
Expand Down

0 comments on commit 6567ed9

Please sign in to comment.