src/js/revealing-modal.js
/**
   * Attach the event listeners to the trigger elements
   *
   * @param {array} triggers - the triggers list
   */
Attach the event listeners to the trigger elements
@param {array} triggers - the triggers list
Attach the event listeners to the trigger elements @param { array } triggers - the triggers list
function _addTriggersEventListeners(triggers) {
    triggers.forEach((el, i) => {
      el.addEventListener('click', (e) => {
        const modal = _getTargetModal(e.currentTarget)
        if (modal) {
          openModal(modal);
        }
      });
    });
  }
function _addTriggersEventListeners ( triggers ) { triggers . forEach ( ( el , i ) => { el . addEventListener ( 'click' , ( e ) => { const modal = _getTargetModal ( e . currentTarget ) if ( modal ) { openModal ( modal ) ; } } ) ; } ) ; }
Attach the event listeners to the trigger elements
 @param {array} triggers - the triggers list
Attach the event listeners to the trigger elements @param { array } triggers - the triggers list