added eventHooks.js module for events