diff --git a/app/javascript/packs/application.ts b/app/javascript/packs/application.ts index d1bb4dd6..5623d52b 100644 --- a/app/javascript/packs/application.ts +++ b/app/javascript/packs/application.ts @@ -1,7 +1,7 @@ require('sweetalert/dist/sweetalert.css'); import start from 'retrospring/common'; -import initAnnouncements from 'retrospring/features/announcement/index'; +import initAnnouncements from 'retrospring/features/announcement'; import initAnswerbox from 'retrospring/features/answerbox/index'; import initInbox from 'retrospring/features/inbox/index'; import initUser from 'retrospring/features/user'; diff --git a/app/javascript/retrospring/features/announcement/close.ts b/app/javascript/retrospring/features/announcement/close.ts index 35504d16..0068d07f 100644 --- a/app/javascript/retrospring/features/announcement/close.ts +++ b/app/javascript/retrospring/features/announcement/close.ts @@ -1,5 +1,5 @@ export default function (event: Event): void { const announcement = (event.target as HTMLElement).closest(".announcement") as HTMLDivElement; - const aId = announcement.dataset.announcementId; - window.localStorage.setItem(`announcement${aId}`, 'true'); + const announcementId = announcement.dataset.announcementId; + window.localStorage.setItem(`announcement${announcementId}`, 'true'); } \ No newline at end of file