David Kimura PRO said over 3 years ago on FullCalendar with StimulusJS :
On the cancel button? You may need to pass the event into the closeModal function and then event.preventDefault()