created background.js file to handle main background logic